about summary refs log tree commit diff
path: root/src/afl-fuzz-run.c
diff options
context:
space:
mode:
authorvan Hauser <vh@thc.org>2020-11-03 16:00:29 +0100
committervan Hauser <vh@thc.org>2020-11-03 16:00:29 +0100
commit3cfc0174f7fac85f232052dffdb1eb83ea3ef24d (patch)
treec79f2a592f84de00ee9e2aa0780c9e1bc2ff2f8c /src/afl-fuzz-run.c
parent7b4d1c408909dd27d81967eced963f3b661511c8 (diff)
downloadafl++-3cfc0174f7fac85f232052dffdb1eb83ea3ef24d.tar.gz
fix -N for forkserver
Diffstat (limited to 'src/afl-fuzz-run.c')
-rw-r--r--src/afl-fuzz-run.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/afl-fuzz-run.c b/src/afl-fuzz-run.c
index fb259b5d..e969994d 100644
--- a/src/afl-fuzz-run.c
+++ b/src/afl-fuzz-run.c
@@ -243,7 +243,7 @@ static void write_with_gap(afl_state_t *afl, u8 *mem, u32 len, u32 skip_at,
 
   } else if (afl->fsrv.out_file) {
 
-    if (afl->no_unlink) {
+    if (unlikely(afl->no_unlink)) {
 
       fd = open(afl->fsrv.out_file, O_WRONLY | O_CREAT | O_TRUNC, 0600);
 
@@ -824,7 +824,7 @@ u8 trim_case(afl_state_t *afl, struct queue_entry *q, u8 *in_buf) {
 
     s32 fd;
 
-    if (afl->no_unlink) {
+    if (unlikely(afl->no_unlink)) {
 
       fd = open(q->fname, O_WRONLY | O_CREAT | O_TRUNC, 0600);