fix comment

This commit is contained in:
Todd C. Miller
1999-04-10 17:03:32 +00:00
parent 06e586ee7b
commit 16fdb0a5c5

View File

@@ -308,10 +308,8 @@ command_matches(cmnd, user_args, path, sudoers_args)
strcpy(buf, path); strcpy(buf, path);
strcat(buf, dent->d_name); strcat(buf, dent->d_name);
/* only stat if basenames are not the same */ /* only stat if basenames are the same */
if (strcmp(cmnd_base, dent->d_name)) if (strcmp(cmnd_base, dent->d_name) != 0 || stat(buf, &pst) == -1)
continue;
if (stat(buf, &pst) == -1)
continue; continue;
if (cst.st_dev == pst.st_dev && cst.st_ino == pst.st_ino) { if (cst.st_dev == pst.st_dev && cst.st_ino == pst.st_ino) {
if (cmnd_safe) if (cmnd_safe)