Commit 072756cd authored by Andreas Cadhalpun's avatar Andreas Cadhalpun Committed by Luca Barbato

vc1dec: use get_bits_long and limit the read bits to 32

get_bits should not be used with more than 25 bits.
Signed-off-by: 's avatarAndreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Signed-off-by: 's avatarLuca Barbato <lu_zero@gentoo.org>
parent 5dbd491e
......@@ -444,7 +444,7 @@ static av_cold int vc1_decode_init(AVCodecContext *avctx)
count = avctx->extradata_size*8 - get_bits_count(&gb);
if (count > 0) {
av_log(avctx, AV_LOG_INFO, "Extra data: %i bits left, value: %X\n",
count, get_bits(&gb, count));
count, get_bits_long(&gb, FFMIN(count, 32)));
} else if (count < 0) {
av_log(avctx, AV_LOG_INFO, "Read %i bits in overflow\n", -count);
}
......
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