avcodec/prosumer: Error out if decompress() stops reading data
authorMichael Niedermayer <michael@niedermayer.cc>
Sat, 12 Jan 2019 21:36:00 +0000 (22:36 +0100)
committerMichael Niedermayer <michael@niedermayer.cc>
Mon, 21 Jan 2019 06:53:26 +0000 (07:53 +0100)
commit31fa50f3d97ca4c722e2b35af7b66a4b44a8f46a
treee214e5dc1b7dee09daf327418b241728d1163313
parent552733d48ba591eb8d6821da428ee2ef42429e49
avcodec/prosumer: Error out if decompress() stops reading data

if 0 is encountered in the LUT then decompress() will continue to output 0 bytes but never read more data.
Without a specification it is impossible to say if this is invalid or a feature.
None of the valid prosumer files tested cause a 0 to be read, so it is likely
not a intended feature.

Fixes: Timeout
Fixes: 11266/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_PROSUMER_fuzzer-5681827423977472

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit 62f8d27ef1995354d6529ea0d9428501d7f914b4)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
libavcodec/prosumer.c