mirror of
https://github.com/AFLplusplus/AFLplusplus.git
synced 2025-06-12 01:58:17 +00:00
update havoc
This commit is contained in:
@ -2002,7 +2002,7 @@ havoc_stage:
|
|||||||
u32 r_max, r;
|
u32 r_max, r;
|
||||||
|
|
||||||
r_max = (MAX_HAVOC_ENTRY + 1) + (afl->extras_cnt ? 4 : 0) +
|
r_max = (MAX_HAVOC_ENTRY + 1) + (afl->extras_cnt ? 4 : 0) +
|
||||||
(afl->a_extras_cnt ? 2 : 0);
|
(afl->a_extras_cnt ? 4 : 0);
|
||||||
|
|
||||||
if (unlikely(afl->expand_havoc && afl->ready_for_splicing_count > 1)) {
|
if (unlikely(afl->expand_havoc && afl->ready_for_splicing_count > 1)) {
|
||||||
|
|
||||||
@ -2587,7 +2587,7 @@ havoc_stage:
|
|||||||
|
|
||||||
if (afl->a_extras_cnt) {
|
if (afl->a_extras_cnt) {
|
||||||
|
|
||||||
if (r == 0) {
|
if (r < 2) {
|
||||||
|
|
||||||
/* Use the dictionary. */
|
/* Use the dictionary. */
|
||||||
|
|
||||||
@ -2607,7 +2607,7 @@ havoc_stage:
|
|||||||
|
|
||||||
break;
|
break;
|
||||||
|
|
||||||
} else if (r == 1) {
|
} else if (r < 4) {
|
||||||
|
|
||||||
u32 use_extra = rand_below(afl, afl->a_extras_cnt);
|
u32 use_extra = rand_below(afl, afl->a_extras_cnt);
|
||||||
u32 extra_len = afl->a_extras[use_extra].len;
|
u32 extra_len = afl->a_extras[use_extra].len;
|
||||||
@ -2636,7 +2636,7 @@ havoc_stage:
|
|||||||
|
|
||||||
} else {
|
} else {
|
||||||
|
|
||||||
r -= 2;
|
r -= 4;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user