From 8c2b6fb34e1aecdb56d5fc97f2300a197c5e5ecb Mon Sep 17 00:00:00 2001 From: "Todd C. Miller" Date: Fri, 12 Aug 2016 15:03:54 -0600 Subject: [PATCH] Flags always have a NULL value. Regression introduced by refactor of set_default_entry(). --- plugins/sudoers/defaults.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/sudoers/defaults.c b/plugins/sudoers/defaults.c index ace368d39..03e33bc74 100644 --- a/plugins/sudoers/defaults.c +++ b/plugins/sudoers/defaults.c @@ -196,7 +196,7 @@ set_default_entry(struct sudo_defs_types *def, const char *val, int op, int rc; debug_decl(set_default_entry, SUDOERS_DEBUG_DEFAULTS) - if (val == NULL) { + if (val == NULL && !ISSET(def->type, T_FLAG)) { /* Check for bogus boolean usage or missing value if non-boolean. */ if (!ISSET(def->type, T_BOOL) || op != false) { if (!quiet) -- 2.50.1