about summary refs log tree commit diff
path: root/src
diff options
context:
space:
mode:
authorvan Hauser <vh@thc.org>2021-01-12 17:36:10 +0100
committervan Hauser <vh@thc.org>2021-01-12 17:36:10 +0100
commit0ddbffd80e6378bdaf8565caeca3990630574d3f (patch)
tree4fb43d9ff534238097f06bd17464cda98984876e /src
parentb9ba2805e537f8033075f90f31b52767f31267dc (diff)
downloadafl++-0ddbffd80e6378bdaf8565caeca3990630574d3f.tar.gz
fix
Diffstat (limited to 'src')
-rw-r--r--src/afl-common.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/afl-common.c b/src/afl-common.c
index 3a7d0ce5..cf996548 100644
--- a/src/afl-common.c
+++ b/src/afl-common.c
@@ -927,14 +927,14 @@ u32 get_map_size(void) {
   if ((ptr = getenv("AFL_MAP_SIZE")) || (ptr = getenv("AFL_MAPSIZE"))) {
 
     map_size = atoi(ptr);
-    if (map_size < 8 || map_size > (1 << 29)) {
+    if (!map_size || map_size > (1 << 29)) {
 
-      FATAL("illegal AFL_MAP_SIZE %u, must be between %u and %u", map_size, 8U,
+      FATAL("illegal AFL_MAP_SIZE %u, must be between %u and %u", map_size, 32U,
             1U << 29);
 
     }
 
-    if (map_size % 8) { map_size = (((map_size >> 3) + 1) << 3); }
+    if (map_size % 32) { map_size = (((map_size >> 5) + 1) << 5); }
 
   }