Commit 9bd854b1 authored by Laurent Aimar's avatar Laurent Aimar Committed by Janne Grunau

mpc8: Check out of bound bands limit

Signed-off-by: 's avatarJanne Grunau <janne-libav@jannau.net>
parent 7d17a794
......@@ -266,6 +266,8 @@ static int mpc8_decode_frame(AVCodecContext * avctx,
maxband = c->last_max_band + get_vlc2(gb, band_vlc.table, MPC8_BANDS_BITS, 2);
if(maxband > 32) maxband -= 33;
}
if(maxband > c->maxbands)
return AVERROR_INVALIDDATA;
c->last_max_band = maxband;
/* read subband indexes */
......
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