Fix pkg_version with the -o argument to print the origin.
Submitted by: Sebastian Stach <sebsta AT t-online DOT de> MFC after: 3 days
This commit is contained in:
parent
f4f2eb1449
commit
0775d47dcc
@ -261,11 +261,12 @@ show_version(Package plist, const char *latest, const char *source)
|
||||
return;
|
||||
if (ShowOrigin != FALSE)
|
||||
strlcpy(tmp, plist.origin, PATH_MAX);
|
||||
else
|
||||
else {
|
||||
strlcpy(tmp, plist.name, PATH_MAX);
|
||||
if (!Verbose) {
|
||||
if ((ch = strrchr(tmp, '-')) != NULL)
|
||||
ch[0] = '\0';
|
||||
if (!Verbose) {
|
||||
if ((ch = strrchr(tmp, '-')) != NULL)
|
||||
ch[0] = '\0';
|
||||
}
|
||||
}
|
||||
if (latest == NULL) {
|
||||
if (source == NULL && OUTPUT('!')) {
|
||||
|
Loading…
Reference in New Issue
Block a user