From: Todd C. Miller Date: Mon, 15 Nov 2004 03:37:53 +0000 (+0000) Subject: Edit all sudoers file if there were unused or undefined aliases and we X-Git-Tag: SUDO_1_7_0~840 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=f3839f1bf0bea435cfc5bfd499dfcebe4681d027;p=sudo Edit all sudoers file if there were unused or undefined aliases and we are in strict mode. --- diff --git a/visudo.c b/visudo.c index 59c1cf6dc..29a2612c6 100644 --- a/visudo.c +++ b/visudo.c @@ -420,7 +420,7 @@ reparse_sudoers(editor, strict, quiet) if (parse_error) { /* Edit file with the parse error */ for (sp = sudoerslist.first; sp != NULL; sp = sp->next) { - if (strcmp(sp->path, errorfile) == 0) { + if (errorfile == NULL || strcmp(sp->path, errorfile) == 0) { edit_sudoers(sp, editor, errorlineno); break; }