Restore the check for sudoers_policy.close == NULL.
The fuzzers run as part of "make check" too in which case NO_LEAKS won't be defined and the close function will be set to NULL.
This commit is contained in:
@@ -341,7 +341,10 @@ LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
|
||||
}
|
||||
|
||||
/* Free resources. */
|
||||
sudoers_policy.close(0, 0);
|
||||
if (sudoers_policy.close != NULL)
|
||||
sudoers_policy.close(0, 0);
|
||||
else
|
||||
sudoers_cleanup();
|
||||
|
||||
/* Call a second time to free old env pointer. */
|
||||
env_init(NULL);
|
||||
|
Reference in New Issue
Block a user