Commit 2f588ccf authored by Michael Niedermayer's avatar Michael Niedermayer

avcodec/vc1_block: Fix invalid left shift in vc1_decode_p_mb()

Fixes: left shift of negative value -6
Fixes: 17810/clusterfuzz-testcase-minimized-ffmpeg_AV_CODEC_ID_VC1_fuzzer-5638541240958976

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpegReviewed-by: 's avatarPaul B Mahol <onemda@gmail.com>
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 9b533de2
...@@ -1481,7 +1481,7 @@ static int vc1_decode_p_mb(VC1Context *v) ...@@ -1481,7 +1481,7 @@ static int vc1_decode_p_mb(VC1Context *v)
v->vc1dsp.vc1_inv_trans_8x8(v->block[v->cur_blk_idx][block_map[i]]); v->vc1dsp.vc1_inv_trans_8x8(v->block[v->cur_blk_idx][block_map[i]]);
if (v->rangeredfrm) if (v->rangeredfrm)
for (j = 0; j < 64; j++) for (j = 0; j < 64; j++)
v->block[v->cur_blk_idx][block_map[i]][j] <<= 1; v->block[v->cur_blk_idx][block_map[i]][j] *= 2;
block_cbp |= 0xF << (i << 2); block_cbp |= 0xF << (i << 2);
block_intra |= 1 << i; block_intra |= 1 << i;
} else if (is_coded[i]) { } else if (is_coded[i]) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment