mirror of
https://github.com/AFLplusplus/AFLplusplus.git
synced 2025-06-17 04:18:06 +00:00
fixed potential double free in custom trim (#881)
This commit is contained in:
@ -508,7 +508,7 @@ u8 fuzz_one_original(afl_state_t *afl) {
|
||||
|
||||
u32 old_len = afl->queue_cur->len;
|
||||
|
||||
u8 res = trim_case(afl, afl->queue_cur, in_buf);
|
||||
u8 res = trim_case(afl, afl->queue_cur, &in_buf);
|
||||
orig_in = in_buf = queue_testcase_get(afl, afl->queue_cur);
|
||||
|
||||
if (unlikely(res == FSRV_RUN_ERROR)) {
|
||||
@ -3007,16 +3007,16 @@ static u8 mopt_common_fuzzing(afl_state_t *afl, MOpt_globals_t MOpt_globals) {
|
||||
|
||||
u32 old_len = afl->queue_cur->len;
|
||||
|
||||
u8 res = trim_case(afl, afl->queue_cur, in_buf);
|
||||
u8 res = trim_case(afl, afl->queue_cur, &in_buf);
|
||||
orig_in = in_buf = queue_testcase_get(afl, afl->queue_cur);
|
||||
|
||||
if (res == FSRV_RUN_ERROR) {
|
||||
if (unlikely(res == FSRV_RUN_ERROR)) {
|
||||
|
||||
FATAL("Unable to execute target application");
|
||||
|
||||
}
|
||||
|
||||
if (afl->stop_soon) {
|
||||
if (unlikely(afl->stop_soon)) {
|
||||
|
||||
++afl->cur_skipped_paths;
|
||||
goto abandon_entry;
|
||||
|
Reference in New Issue
Block a user