diff options
| author | Maxim Sobolev <sobomax@FreeBSD.org> | 2002-05-02 13:09:33 +0000 |
|---|---|---|
| committer | Maxim Sobolev <sobomax@FreeBSD.org> | 2002-05-02 13:09:33 +0000 |
| commit | 3d5c1511ca0ec8f72ebdfc749fbac99da4f2f48c (patch) | |
| tree | adb99b8fce153a3b2dde7db2f550a139ab1dd6f8 /usr.sbin | |
| parent | 5583155096d738b489bf70c5e937dccafb8b9197 (diff) | |
Notes
Diffstat (limited to 'usr.sbin')
| -rw-r--r-- | usr.sbin/pkg_install/info/main.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/usr.sbin/pkg_install/info/main.c b/usr.sbin/pkg_install/info/main.c index ae62a38d554a..807f9608c7ea 100644 --- a/usr.sbin/pkg_install/info/main.c +++ b/usr.sbin/pkg_install/info/main.c @@ -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'; /* |
