From 43458f7e8b4963f2c3fbade69379c2d2e0654989 Mon Sep 17 00:00:00 2001 From: Your Name Date: Wed, 17 Nov 2021 20:27:45 +0000 Subject: Disable fetching adjacent blocks when coverage is enabled --- frida_mode/src/stalker.c | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) diff --git a/frida_mode/src/stalker.c b/frida_mode/src/stalker.c index 65ed5d50..b4dd5a47 100644 --- a/frida_mode/src/stalker.c +++ b/frida_mode/src/stalker.c @@ -111,10 +111,23 @@ void stalker_init(void) { } #endif - if (stalker_ic_entries == 0) { stalker_ic_entries = 32; } - if (stalker_adjacent_blocks == 0) { stalker_adjacent_blocks = 32; } + if (instrument_coverage_filename == NULL) { + + if (stalker_adjacent_blocks == 0) { stalker_adjacent_blocks = 32; } + + } else { + + if (stalker_adjacent_blocks != 0) { + + FFATAL( + "AFL_FRIDA_STALKER_ADJACENT_BLOCKS and AFL_FRIDA_INST_COVERAGE_FILE " + "are incompatible"); + + } + + } #if defined(__x86_64__) || defined(__i386__) stalker = g_object_new(GUM_TYPE_STALKER, "ic-entries", stalker_ic_entries, -- cgit 1.4.1