avcodec/pngdec: Check that previous_picture has same w/h/format
authorMichael Niedermayer <michael@niedermayer.cc>
Wed, 10 Jul 2019 21:02:36 +0000 (23:02 +0200)
committerMichael Niedermayer <michael@niedermayer.cc>
Sat, 13 Jul 2019 12:42:57 +0000 (14:42 +0200)
commit18c808ffbed81ea580fe6ddd6524dd7bea3f8d0e
treef46fd38da7c21568d7a899d1817debda49d2dbf6
parent9ffa32b81bede1dbb167dfceb48fe605b27a0890
avcodec/pngdec: Check that previous_picture has same w/h/format

Fixes: out of array access
Fixes: 15540/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_APNG_fuzzer-5684905029140480

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Reviewed-by: Paul B Mahol <onemda@gmail.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
libavcodec/pngdec.c