Commit 8a0cd587 authored by Michael Niedermayer's avatar Michael Niedermayer

sonic: fix FPE

Fixes Ticket1397
Found-by: 's avatarPiotr Bandurski <ami_stuff@o2.pl>
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent dc30c27e
......@@ -796,6 +796,11 @@ static av_cold int sonic_decode_init(AVCodecContext *avctx)
s->decorrelation = get_bits(&gb, 2);
s->downsampling = get_bits(&gb, 2);
if (!s->downsampling) {
av_log(avctx, AV_LOG_ERROR, "invalid downsampling value\n");
return AVERROR_INVALIDDATA;
}
s->num_taps = (get_bits(&gb, 5)+1)<<5;
if (get_bits1(&gb)) // XXX FIXME
av_log(avctx, AV_LOG_INFO, "Custom quant table\n");
......
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