about summary refs log tree commit diff
path: root/src/afl-fuzz-one.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/afl-fuzz-one.c')
-rw-r--r--src/afl-fuzz-one.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/afl-fuzz-one.c b/src/afl-fuzz-one.c
index b1bbad0a..2e49e19b 100644
--- a/src/afl-fuzz-one.c
+++ b/src/afl-fuzz-one.c
@@ -1621,8 +1621,6 @@ custom_mutator_stage:
     if (unlikely(!mutated_buf))
       FATAL("Error in custom_fuzz. Size returned: %zd", mutated_size);
 
-    if (mutated_size > len) afl->out_size = mutated_size;
-
     if (mutated_size > 0) {
 
       if (common_fuzz_stuff(afl, mutated_buf, (u32)mutated_size)) {
@@ -1649,7 +1647,7 @@ custom_mutator_stage:
 
     }
 
-    out_buf = ck_maybe_grow(BUF_PARAMS(out), len);
+    /* `(afl->)out_buf` may have been changed by the call to custom_fuzz */
     memcpy(out_buf, in_buf, len);
 
   }