Commit 807fa714 authored by Michael Niedermayer's avatar Michael Niedermayer

adpcmdec: Fix OOM/infloop

Found-by: ami_stuff
Signed-off-by: 's avatarMichael Niedermayer <michaelni@gmx.at>
parent 34b6f1ef
......@@ -1355,6 +1355,11 @@ static int adpcm_decode_frame(AVCodecContext *avctx, void *data,
return -1;
}
if (avpkt->size && bytestream2_tell(&gb) == 0) {
av_log(avctx, AV_LOG_ERROR, "Nothing consumed\n");
return AVERROR_INVALIDDATA;
}
*got_frame_ptr = 1;
*(AVFrame *)data = c->frame;
......
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