about summary refs log tree commit diff
diff options
context:
space:
mode:
authorAndrea Fioraldi <andreafioraldi@gmail.com>2021-02-04 13:32:54 +0100
committerGitHub <noreply@github.com>2021-02-04 13:32:54 +0100
commit208254f47c146291e580637d583e1be19cd094d2 (patch)
tree38c9fa22c4f64ee337ec7c83fb20219c211d7109
parent58a5372bf0c55ead2a04ed4a4a5b651d68e69292 (diff)
parentd0ab2ded0010fbb2f07920ebcf16bea818507378 (diff)
downloadafl++-208254f47c146291e580637d583e1be19cd094d2.tar.gz
Merge pull request #726 from b1gr3db/dev
Fix for off by one in libqasan's memmem
-rw-r--r--qemu_mode/libqasan/string.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/qemu_mode/libqasan/string.c b/qemu_mode/libqasan/string.c
index c850463b..4be01279 100644
--- a/qemu_mode/libqasan/string.c
+++ b/qemu_mode/libqasan/string.c
@@ -271,7 +271,7 @@ void *__libqasan_memmem(const void *haystack, size_t haystack_len,
 
     }
 
-  } while (h++ <= end);
+  } while (++h <= end);
 
   return 0;