Browse Source

Test extradata size before reading from extradata when decoding avui.

(cherry picked from commit 83de4f5fc9)

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
tags/n0.11.1
Carl Eugen Hoyos Michael Niedermayer 13 years ago
parent
commit
c4e3dd06e8
1 changed files with 2 additions and 2 deletions
  1. +2
    -2
      libavcodec/avuidec.c

+ 2
- 2
libavcodec/avuidec.c View File

@@ -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;


Loading…
Cancel
Save