TurboJPEG: New flag for limiting prog JPEG scans

This also fixes timeouts reported by OSS-Fuzz.
This commit is contained in:
DRC
2021-04-05 16:08:22 -05:00
parent bff7959e34
commit c81e91e8ca
34 changed files with 384 additions and 215 deletions

View File

@@ -100,7 +100,7 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size)
goto bailout;
tjTransform(handle, data, size, NUMXFORMS, dstBufs, dstSizes, transforms,
TJFLAG_NOREALLOC);
TJFLAG_LIMITSCANS | TJFLAG_NOREALLOC);
maxBufSize = tjBufSize(width, height, jpegSubsamp);