fix shared memory leaks in afl-showmap, initialize cmplog_mode

This commit is contained in:
hexcoder-
2020-06-26 01:14:21 +02:00
parent 8bd8442bcc
commit 07fead0466
4 changed files with 20 additions and 2 deletions

View File

@ -1049,6 +1049,9 @@ int main(int argc, char **argv, char **envp) {
check_environment_vars(envp);
sharedmem_t shm = {0};
/* initialize cmplog_mode */
shm.cmplog_mode = 0;
trace_bits = afl_shm_init(&shm, map_size, 0);
atexit(at_exit_handler);
setup_signal_handlers();