avcodec/bitstream: Check for integer code truncation in build_table()
authorMichael Niedermayer <michael@niedermayer.cc>
Wed, 5 Jun 2019 10:18:54 +0000 (12:18 +0200)
committerMichael Niedermayer <michael@niedermayer.cc>
Thu, 27 Jun 2019 15:50:47 +0000 (17:50 +0200)
commitec23fe0fd908e78b0bf23cf2b880dcb7a7c5640a
tree62ceafd0b3ead0b0257605e81fe755a8c0171271
parent837e9e8898f3110cc6328d35ca77eda4fc630820
avcodec/bitstream: Check for integer code truncation in build_table()

Fixes: out of array read
Fixes: 14563/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_AGM_fuzzer-5646451545210880

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 e78b0f83748f92ea9e93b21c36082e0dd04d7cb1)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
libavcodec/bitstream.c