about summary refs log tree commit diff
path: root/src/afl-forkserver.c
diff options
context:
space:
mode:
authorhexcoder <hexcoder-@users.noreply.github.com>2021-05-31 19:18:24 +0200
committerGitHub <noreply@github.com>2021-05-31 19:18:24 +0200
commit97a1f89881878db9bd6b4cd666b3447a63818dcf (patch)
tree46e844356f7cf88c08f9f9907caa11656a24f416 /src/afl-forkserver.c
parentb246de789105750558f3d6f884ba61e54cb98441 (diff)
parent1a2da67ed0505c9ac0aa1048ba3d607f3c1aa639 (diff)
downloadafl++-97a1f89881878db9bd6b4cd666b3447a63818dcf.tar.gz
Merge branch 'dev' into going_atomic
Diffstat (limited to 'src/afl-forkserver.c')
-rw-r--r--src/afl-forkserver.c13
1 files changed, 9 insertions, 4 deletions
diff --git a/src/afl-forkserver.c b/src/afl-forkserver.c
index 727e7f8d..3d472b36 100644
--- a/src/afl-forkserver.c
+++ b/src/afl-forkserver.c
@@ -416,7 +416,8 @@ void afl_fsrv_start(afl_forkserver_t *fsrv, char **argv,
 
     struct rlimit r;
 
-    if (!fsrv->cmplog_binary && fsrv->qemu_mode == false) {
+    if (!fsrv->cmplog_binary && fsrv->qemu_mode == false &&
+        fsrv->frida_mode == false) {
 
       unsetenv(CMPLOG_SHM_ENV_VAR);  // we do not want that in non-cmplog fsrv
 
@@ -450,8 +451,12 @@ void afl_fsrv_start(afl_forkserver_t *fsrv, char **argv,
     /* Dumping cores is slow and can lead to anomalies if SIGKILL is delivered
        before the dump is complete. */
 
-    //    r.rlim_max = r.rlim_cur = 0;
-    //    setrlimit(RLIMIT_CORE, &r);                      /* Ignore errors */
+    if (!fsrv->debug) {
+
+      r.rlim_max = r.rlim_cur = 0;
+      setrlimit(RLIMIT_CORE, &r);                          /* Ignore errors */
+
+    }
 
     /* Isolate the process and configure standard descriptors. If out_file is
        specified, stdin is /dev/null; otherwise, out_fd is cloned instead. */
@@ -1089,7 +1094,7 @@ void afl_fsrv_write_to_testcase(afl_forkserver_t *fsrv, u8 *buf, size_t len) {
 
 #endif
 
-  if (likely(fsrv->use_shmem_fuzz && fsrv->shmem_fuzz)) {
+  if (likely(fsrv->use_shmem_fuzz)) {
 
     if (unlikely(len > MAX_FILE)) len = MAX_FILE;