diff options
author | Andrea Fioraldi <andreafioraldi@gmail.com> | 2020-10-28 14:36:49 +0100 |
---|---|---|
committer | Andrea Fioraldi <andreafioraldi@gmail.com> | 2020-10-28 14:36:49 +0100 |
commit | 93c9093817e23378e880807df42f047e1bd6dd97 (patch) | |
tree | e49d3429e0a561e3767d44e1091da70944379c01 /src/afl-fuzz-one.c | |
parent | 868cb61ea6a2949e80e8a94fe7b19229bebecd10 (diff) | |
parent | fe705bb9567341427ce1ea39d5fc6b19fdee1646 (diff) | |
download | afl++-93c9093817e23378e880807df42f047e1bd6dd97.tar.gz |
merge conflict
Diffstat (limited to 'src/afl-fuzz-one.c')
-rw-r--r-- | src/afl-fuzz-one.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/afl-fuzz-one.c b/src/afl-fuzz-one.c index 1e63abc7..35ff5466 100644 --- a/src/afl-fuzz-one.c +++ b/src/afl-fuzz-one.c @@ -1840,16 +1840,22 @@ havoc_stage: u32 r_max, r; + r_max = 15 + ((afl->extras_cnt + afl->a_extras_cnt) ? 2 : 0); + if (unlikely(afl->expand_havoc && afl->ready_for_splicing_count > 1)) { /* add expensive havoc cases here, they are activated after a full cycle without finds happened */ - r_max = 16 + ((afl->extras_cnt + afl->a_extras_cnt) ? 2 : 0); + r_max += 1; - } else { + } + + if (unlikely(get_cur_time() - afl->last_path_time > 5000)) { + + /* add expensive havoc cases here if there is no findings in the last 5s */ - r_max = 15 + ((afl->extras_cnt + afl->a_extras_cnt) ? 2 : 0); + r_max += 1; } |