summaryrefslogtreecommitdiffstats
path: root/libavcodec/avuidec.c
diff options
context:
space:
mode:
authorCarl Eugen Hoyos <cehoyos@ag.or.at>2012-05-28 15:58:46 +0200
committerCarl Eugen Hoyos <cehoyos@ag.or.at>2012-05-28 15:58:46 +0200
commit83de4f5fc92b1424c7d77f3411572a9a00eff672 (patch)
tree0fc7fe1e2c67928c0dccdc0b72e412fed639f5e0 /libavcodec/avuidec.c
parentd5a17d7f4d03d174c0cc6111fed07ebded0ac6f3 (diff)
downloadffmpeg-streaming-83de4f5fc92b1424c7d77f3411572a9a00eff672.zip
ffmpeg-streaming-83de4f5fc92b1424c7d77f3411572a9a00eff672.tar.gz
Test extradata size before reading from extradata when decoding avui.
Diffstat (limited to 'libavcodec/avuidec.c')
-rw-r--r--libavcodec/avuidec.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/avuidec.c b/libavcodec/avuidec.c
index a1beb37..32fd819 100644
--- a/libavcodec/avuidec.c
+++ b/libavcodec/avuidec.c
@@ -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;
OpenPOWER on IntegriCloud