Don't try to install the temporary sudoers file if we didn't edit it.
By default, visudo does not edit files in a #includedir. Fixes a NULL pointer defef on GNU hurd; Bug #647
This commit is contained in:
@@ -266,6 +266,7 @@ main(int argc, char *argv[])
|
||||
*/
|
||||
if (reparse_sudoers(editor, args, strict, quiet)) {
|
||||
TAILQ_FOREACH(sp, &sudoerslist, entries) {
|
||||
if (sp->doedit)
|
||||
(void) install_sudoers(sp, oldperms);
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user