Commit 83de4f5f authored by Carl Eugen Hoyos's avatar Carl Eugen Hoyos

Test extradata size before reading from extradata when decoding avui.

parent d5a17d7f
......@@ -48,8 +48,8 @@ static int avui_decode_frame(AVCodecContext *avctx, void *data,
if (pic->data[0])
avctx->release_buffer(avctx, pic);
if (!memcmp(&avctx->extradata[4], "APRGAPRG0001", 12) &&
avctx->extradata_size >= 24)
if (avctx->extradata_size >= 24 &&
!memcmp(&avctx->extradata[4], "APRGAPRG0001", 12))
interlaced = avctx->extradata[19] != 1;
if (avctx->height == 486) {
skip = 10;
......
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