Commit 580021cf authored by Michael Niedermayer's avatar Michael Niedermayer

wavpack: check ch_offset

Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent e9cb533f
......@@ -789,6 +789,11 @@ static int wavpack_decode_block(AVCodecContext *avctx, int block_no,
return -1;
}
if (wc->ch_offset >= avctx->channels) {
av_log(avctx, AV_LOG_ERROR, "too many channels\n");
return -1;
}
memset(s->decorr, 0, MAX_TERMS * sizeof(Decorr));
memset(s->ch, 0, sizeof(s->ch));
s->extra_bits = 0;
......
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