fix syncing with custom mutator

This commit is contained in:
vanhauser-thc 2024-04-11 09:40:28 +02:00
parent 72226d6f89
commit b08df87f5c

View File

@ -822,7 +822,7 @@ void sync_fuzzers(afl_state_t *afl) {
/* See what happens. We rely on save_if_interesting() to catch major /* See what happens. We rely on save_if_interesting() to catch major
errors and save the test case. */ errors and save the test case. */
(void)write_to_testcase(afl, (void **)&mem, st.st_size, 1); u32 new_len = write_to_testcase(afl, (void **)&mem, st.st_size, 1);
fault = fuzz_run_target(afl, &afl->fsrv, afl->fsrv.exec_tmout); fault = fuzz_run_target(afl, &afl->fsrv, afl->fsrv.exec_tmout);
@ -830,7 +830,7 @@ void sync_fuzzers(afl_state_t *afl) {
afl->syncing_party = sd_ent->d_name; afl->syncing_party = sd_ent->d_name;
afl->queued_imported += afl->queued_imported +=
save_if_interesting(afl, mem, st.st_size, fault); save_if_interesting(afl, mem, new_len, fault);
afl->syncing_party = 0; afl->syncing_party = 0;
munmap(mem, st.st_size); munmap(mem, st.st_size);