about summary refs log tree commit diff
path: root/src/afl-fuzz-init.c
diff options
context:
space:
mode:
authorvanhauser-thc <vh@thc.org>2020-10-23 22:49:20 +0200
committervanhauser-thc <vh@thc.org>2020-10-23 22:49:20 +0200
commit2e8ec1e33943c5067637361a8c182d13412a307c (patch)
tree1a6922223d2eec0362c8d38a496e84e50fe1a4df /src/afl-fuzz-init.c
parentaa0d3785206d52c1815aff850817d55bf50f3598 (diff)
downloadafl++-2e8ec1e33943c5067637361a8c182d13412a307c.tar.gz
allow symbolize=1 for asan/debug
Diffstat (limited to 'src/afl-fuzz-init.c')
-rw-r--r--src/afl-fuzz-init.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/afl-fuzz-init.c b/src/afl-fuzz-init.c
index 13e42e03..1bccff8f 100644
--- a/src/afl-fuzz-init.c
+++ b/src/afl-fuzz-init.c
@@ -2338,10 +2338,12 @@ static void handle_resize(int sig) {
 
 /* Check ASAN options. */
 
-void check_asan_opts(void) {
+void check_asan_opts(afl_state_t *afl) {
 
   u8 *x = get_afl_env("ASAN_OPTIONS");
 
+  (void)(afl);
+
   if (x) {
 
     if (!strstr(x, "abort_on_error=1")) {
@@ -2350,11 +2352,13 @@ void check_asan_opts(void) {
 
     }
 
-    if (!strstr(x, "symbolize=0")) {
+#ifndef ASAN_BUILD
+    if (!afl->debug && !strstr(x, "symbolize=0")) {
 
       FATAL("Custom ASAN_OPTIONS set without symbolize=0 - please fix!");
 
     }
+#endif
 
   }