[FFmpeg-cvslog] Test extradata size before reading from extradata when decoding avui.
Carl Eugen Hoyos
git at videolan.org
Mon May 28 15:59:34 CEST 2012
ffmpeg | branch: master | Carl Eugen Hoyos <cehoyos at ag.or.at> | Mon May 28 15:58:46 2012 +0200| [83de4f5fc92b1424c7d77f3411572a9a00eff672] | committer: Carl Eugen Hoyos
Test extradata size before reading from extradata when decoding avui.
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=83de4f5fc92b1424c7d77f3411572a9a00eff672
---
libavcodec/avuidec.c | 4 ++--
1 file 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;
More information about the ffmpeg-cvslog
mailing list