Handle relative and absolute pathnames (anything with a `/' in it) in the same
way as execve(2), and the old perl which(1). PR: 35718
This commit is contained in:
parent
8c821782f8
commit
721da592c4
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=99120
@ -129,7 +129,7 @@ print_matches(char *path, char *filename)
|
||||
const char *d;
|
||||
int found;
|
||||
|
||||
if (*filename == '/')
|
||||
if (strchr(filename, '/') != NULL)
|
||||
return (is_there(filename) ? 0 : -1);
|
||||
found = 0;
|
||||
while ((d = strsep(&path, ":")) != NULL) {
|
||||
|
Loading…
Reference in New Issue
Block a user