diff options
author | Michael Niedermayer <michael@niedermayer.cc> | 2017-05-06 15:17:29 +0200 |
---|---|---|
committer | Michael Niedermayer <michael@niedermayer.cc> | 2017-05-14 12:20:15 +0200 |
commit | 054a16d37562cc62de2cbb54968f8ba49603ef39 (patch) | |
tree | 8b0a03e1f1b20e7a1519c2fec55d0450c93016a1 | |
parent | aa39ca14d67fd2119e39a51cbfd03bd0175312be (diff) | |
download | ffmpeg-054a16d37562cc62de2cbb54968f8ba49603ef39.tar.gz |
avcodec/mimic: Fix runtime error: left shift of negative value -1
Fixes: 1365/clusterfuzz-testcase-minimized-5624158450876416
Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/targets/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
(cherry picked from commit fc2c420b82939a8f30838a6aa08bfd936099d3ce)
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
-rw-r--r-- | libavcodec/mimic.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/mimic.c b/libavcodec/mimic.c index 06fb393b92..ce649c602a 100644 --- a/libavcodec/mimic.c +++ b/libavcodec/mimic.c @@ -262,7 +262,7 @@ static int vlc_decode_block(MimicContext *ctx, int num_coeffs, int qscale) coeff = vlcdec_lookup[num_bits][value]; if (pos < 3) - coeff <<= 4; + coeff *= 16; else /* TODO Use >> 10 instead of / 1001 */ coeff = (coeff * qscale) / 1001; |