diff --git a/usr.sbin/pkg_install/delete/main.c b/usr.sbin/pkg_install/delete/main.c index c75d73a627a1..3100ae35772b 100644 --- a/usr.sbin/pkg_install/delete/main.c +++ b/usr.sbin/pkg_install/delete/main.c @@ -121,7 +121,7 @@ main(int argc, char **argv) * package name. Otherwise we've come across a trailing '/' and * need to continue our quest. */ - if (isalpha(*pkgs_split) || ((MatchType == MATCH_GLOB) && \ + if (isalnum(*pkgs_split) || ((MatchType == MATCH_GLOB) && \ strpbrk(pkgs_split, "*?[]") != NULL)) { *argv = pkgs_split; break; diff --git a/usr.sbin/pkg_install/info/main.c b/usr.sbin/pkg_install/info/main.c index d98593895ff0..b22c54c3d3c0 100644 --- a/usr.sbin/pkg_install/info/main.c +++ b/usr.sbin/pkg_install/info/main.c @@ -240,7 +240,7 @@ main(int argc, char **argv) * we've come across a trailing '/' and need to continue our * quest. */ - if (isalpha(*pkgs_split) || ((MatchType == MATCH_GLOB) && \ + if (isalnum(*pkgs_split) || ((MatchType == MATCH_GLOB) && \ strpbrk(pkgs_split, "*?[]") != NULL)) { *argv = pkgs_split; break;