diff --git a/plugins/sudoers/defaults.c b/plugins/sudoers/defaults.c index 832c8ad77..da42a969e 100644 --- a/plugins/sudoers/defaults.c +++ b/plugins/sudoers/defaults.c @@ -334,10 +334,6 @@ set_default(char *var, char *val, int op) return(FALSE); } cur->sd_un.flag = op; - - /* Special action for I_FQDN. Move to own switch if we get more */ - if (num == I_FQDN && op) - set_fqdn(); break; case T_LIST: if (!val) { diff --git a/plugins/sudoers/sudoers.c b/plugins/sudoers/sudoers.c index 0879353ac..28b28515c 100644 --- a/plugins/sudoers/sudoers.c +++ b/plugins/sudoers/sudoers.c @@ -262,6 +262,9 @@ sudoers_policy_open(unsigned int version, sudo_conv_t conversation, if (!update_defaults(SETDEF_RUNAS)) log_error(NO_STDERR|NO_EXIT, "problem with defaults entries"); + if (def_fqdn) + set_fqdn(); /* deferred until after sudoers is parsed */ + /* Set login class if applicable. */ set_loginclass(sudo_user.pw);