diff --git a/plugins/sudoers/gram.c b/plugins/sudoers/gram.c index e5f1ca3d5..b3dc644ce 100644 --- a/plugins/sudoers/gram.c +++ b/plugins/sudoers/gram.c @@ -3974,6 +3974,7 @@ free_parse_tree(struct sudoers_parse_tree *parse_tree) if (parse_tree->shost != parse_tree->lhost) free(parse_tree->shost); parse_tree->lhost = parse_tree->shost = NULL; + parse_tree->nss = NULL; } /* diff --git a/plugins/sudoers/gram.y b/plugins/sudoers/gram.y index 16244e6ae..6563d1f4a 100644 --- a/plugins/sudoers/gram.y +++ b/plugins/sudoers/gram.y @@ -1791,6 +1791,7 @@ free_parse_tree(struct sudoers_parse_tree *parse_tree) if (parse_tree->shost != parse_tree->lhost) free(parse_tree->shost); parse_tree->lhost = parse_tree->shost = NULL; + parse_tree->nss = NULL; } /*