Make pkg_info working again when argument is a file not in the current
directory. PR: 37571 Submitted by: Dirk Meyer <dirk.meyer@dinoex.sub.org> MFC after: 1 week
This commit is contained in:
parent
5583155096
commit
3d5c1511ca
@ -187,8 +187,11 @@ main(int argc, char **argv)
|
||||
|
||||
/* Get all the remaining package names, if any */
|
||||
while (*argv) {
|
||||
/* Don't try to apply heuristics if arguments are regexs */
|
||||
if (MatchType != MATCH_REGEX)
|
||||
/*
|
||||
* Don't try to apply heuristics if arguments are regexs or if
|
||||
* the argument refers to an existing file.
|
||||
*/
|
||||
if (MatchType != MATCH_REGEX && !isfile(*argv))
|
||||
while ((pkgs_split = strrchr(*argv, (int)'/')) != NULL) {
|
||||
*pkgs_split++ = '\0';
|
||||
/*
|
||||
|
Loading…
x
Reference in New Issue
Block a user