aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/ivi_common.c
diff options
context:
space:
mode:
authorLuca Barbato <lu_zero@gentoo.org>2013-07-14 18:16:56 +0200
committerSean McGovern <gseanmcg@gmail.com>2013-09-23 19:11:37 -0400
commit36921fcdd3613dedd4046b59e3f43024fbfbbe17 (patch)
treed3396355d78b8b4c64093815c409b19d21bf2f02 /libavcodec/ivi_common.c
parente2dcb8208e8f6cffef58a85127765047f5ef8868 (diff)
downloadffmpeg-36921fcdd3613dedd4046b59e3f43024fbfbbe17.tar.gz
indeo: Reject impossible FRAMETYPE_NULL
A frame marked FRAMETYPE_NULL cannot be scalable and requires a previous frame successfully decoded. Reported-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind CC: libav-stable@libav.org (cherry picked from commit 5b2a29552ca09edd4646b6aa1828b32912b7ab36) Signed-off-by: Luca Barbato <lu_zero@gentoo.org>
Diffstat (limited to 'libavcodec/ivi_common.c')
-rw-r--r--libavcodec/ivi_common.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/libavcodec/ivi_common.c b/libavcodec/ivi_common.c
index c907e2a4d1..0dc7fa29f0 100644
--- a/libavcodec/ivi_common.c
+++ b/libavcodec/ivi_common.c
@@ -820,6 +820,14 @@ int ff_ivi_decode_frame(AVCodecContext *avctx, void *data, int *data_size,
}
}
}
+ } else {
+ if (ctx->is_scalable)
+ return AVERROR_INVALIDDATA;
+
+ for (p = 0; p < 3; p++) {
+ if (!ctx->planes[p].bands[0].buf)
+ return AVERROR_INVALIDDATA;
+ }
}
//STOP_TIMER("decode_planes"); }