about summary refs log tree commit diff
path: root/instrumentation/afl-compiler-rt.o.c
diff options
context:
space:
mode:
authorvan Hauser <vh@thc.org>2024-08-19 16:51:42 +0200
committerGitHub <noreply@github.com>2024-08-19 16:51:42 +0200
commitf27cbdb79349d6f4f6e859a356758b634be72652 (patch)
tree8e1dbb1b8454c470aa5e0093f6d89c5cc86e9200 /instrumentation/afl-compiler-rt.o.c
parentdb23931e7c1727ddac8691a6241c97b2203ec6fc (diff)
parent1689a8e053c1f73e16331bfeda28c79e1ed4bbd0 (diff)
downloadafl++-f27cbdb79349d6f4f6e859a356758b634be72652.tar.gz
Merge pull request #2190 from AFLplusplus/dev
push to stable
Diffstat (limited to 'instrumentation/afl-compiler-rt.o.c')
-rw-r--r--instrumentation/afl-compiler-rt.o.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/instrumentation/afl-compiler-rt.o.c b/instrumentation/afl-compiler-rt.o.c
index 6e04ae47..0da689b2 100644
--- a/instrumentation/afl-compiler-rt.o.c
+++ b/instrumentation/afl-compiler-rt.o.c
@@ -886,11 +886,11 @@ static void __afl_start_forkserver(void) {
   /* Phone home and tell the parent that we're OK. If parent isn't there,
      assume we're not running in forkserver mode and just execute program. */
 
-  // return because possible non-forkserver usage
-  if (write(FORKSRV_FD + 1, msg, 4) != 4) { return; }
-
   if (!__afl_old_forkserver) {
 
+    // return because possible non-forkserver usage
+    if (write(FORKSRV_FD + 1, msg, 4) != 4) { return; }
+
     if (read(FORKSRV_FD, reply, 4) != 4) { _exit(1); }
     if (tmp != status2) {