diff options
author | Yann Collet <cyan@fb.com> | 2020-09-17 17:32:05 (GMT) |
---|---|---|
committer | Yann Collet <cyan@fb.com> | 2020-09-17 17:32:05 (GMT) |
commit | cfd1d8f9d0bf17ef69a789d9238e6e88f1b45275 (patch) | |
tree | fef657d12e84fad795b98068ac4b32c2e7d98a17 | |
parent | b4a64e0eac8f39415b2fa3573561f9325f7296c1 (diff) | |
parent | da1272979f4b79a7066631335a68512350a071fb (diff) | |
download | lz4-cfd1d8f9d0bf17ef69a789d9238e6e88f1b45275.zip lz4-cfd1d8f9d0bf17ef69a789d9238e6e88f1b45275.tar.gz lz4-cfd1d8f9d0bf17ef69a789d9238e6e88f1b45275.tar.bz2 |
Merge branch 'usan_null' of github.com:lz4/lz4 into usan_null
-rw-r--r-- | tests/fuzzer.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/tests/fuzzer.c b/tests/fuzzer.c index 5ca0d31..1d8b5f6 100644 --- a/tests/fuzzer.c +++ b/tests/fuzzer.c @@ -1059,8 +1059,11 @@ static void FUZ_unitTests(int compressionLevel) /* useful to trigger undefined sanitizer */ DISPLAYLEVEL(3, "LZ4_compress_default() with NULL input \n"); { int const maxCSize = LZ4_compressBound(0); - int const cSize = LZ4_compress_default(NULL, testCompressed, 0, maxCSize); - FUZ_CHECKTEST(cSize==1 && testCompressed[0]==0, "compressed empty is byte 0"); + int const cSize = LZ4_compress_default(NULL, testCompressed, 0, maxCSize); + FUZ_CHECKTEST(!(cSize==1 && testCompressed[0]==0), + "compressing empty should give byte 0" + " (maxCSize == %u) (cSize == %u)", + (unsigned)maxCSize, (unsigned)cSize); } /* in-place compression test */ |