diff options
author | Alexander Shvedov <60114847+a-shvedov@users.noreply.github.com> | 2024-05-30 10:43:01 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-05-30 10:43:01 +0300 |
commit | f8a5f1cd9ea907654f42fa06ce6b6bfd4b8c1b13 (patch) | |
tree | 7aec2a095a30ed609ce96f85ec3c4e0a8b8eb74c /test/test-cmplog.c | |
parent | 629edb1e78d791894ce9ee6d53259f95fe1a29af (diff) | |
parent | e7d871c8bf64962a658e447b90a1a3b43aaddc28 (diff) | |
download | afl++-f8a5f1cd9ea907654f42fa06ce6b6bfd4b8c1b13.tar.gz |
Merge branch 'AFLplusplus:stable' into stable
Diffstat (limited to 'test/test-cmplog.c')
-rw-r--r-- | test/test-cmplog.c | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/test/test-cmplog.c b/test/test-cmplog.c index bd1b73e3..0c91b21c 100644 --- a/test/test-cmplog.c +++ b/test/test-cmplog.c @@ -8,16 +8,11 @@ int LLVMFuzzerTestOneInput(const uint8_t *buf, size_t i) { - if (i < 30) return -1; + if (i < 15) return -1; if (buf[0] != 'A') return 0; - if (buf[1] != 'B') return 0; - if (buf[2] != 'C') return 0; - if (buf[3] != 'D') return 0; - int *icmp = (int *)(buf + 4); + int *icmp = (int *)(buf + 1); if (*icmp != 0x69694141) return 0; - if (memcmp(buf + 8, "1234", 4) || memcmp(buf + 12, "EFGH", 4)) return 0; - if (strncmp(buf + 16, "IJKL", 4) == 0 && strcmp(buf + 20, "DEADBEEF") == 0) - abort(); + if (memcmp(buf + 5, "1234EF", 6) == 0) abort(); return 0; } |