diff --git a/fuzz/decompress.cc b/fuzz/decompress.cc index bad32524..022336aa 100644 --- a/fuzz/decompress.cc +++ b/fuzz/decompress.cc @@ -71,10 +71,10 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) int w = width, h = height; /* Test non-default decompression options on the first iteration. */ - if (pf == TJPF_RGB) + if (pfi == 0) flags |= TJFLAG_BOTTOMUP | TJFLAG_FASTUPSAMPLE | TJFLAG_FASTDCT; /* Test IDCT scaling on the second iteration. */ - if (pf == TJPF_BGRX) { + else if (pfi == 1) { w = (width + 1) / 2; h = (height + 1) / 2; } diff --git a/fuzz/decompress_yuv.cc b/fuzz/decompress_yuv.cc index dc4620c5..a8a7302f 100644 --- a/fuzz/decompress_yuv.cc +++ b/fuzz/decompress_yuv.cc @@ -68,10 +68,10 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) int w = width, h = height; /* Test non-default decompression options on the first iteration. */ - if (pf == TJPF_RGB) + if (pfi == 0) flags |= TJFLAG_BOTTOMUP | TJFLAG_FASTUPSAMPLE | TJFLAG_FASTDCT; /* Test IDCT scaling on the second iteration. */ - if (pf == TJPF_XRGB) { + else if (pfi == 1) { w = (width + 3) / 4; h = (height + 3) / 4; }