aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2014-01-19 16:44:58 +0100
committerCarl Eugen Hoyos <cehoyos@ag.or.at>2014-01-20 22:39:50 +0100
commitb902ba478c81909422668fa7da7878848d792e52 (patch)
tree72eefbe563c92971948255a88ec78a3b74c336c1 /libavcodec
parentf0fabcc6ed0d6e1db9630ce975afeec2bfa3ede7 (diff)
downloadffmpeg-b902ba478c81909422668fa7da7878848d792e52.tar.gz
avcodec/mjpegdec: Dont skip picture allocation if theres no picture allocated
Fixes Ticket 3245 (cherry picked from commit ad8d063f230c05f8b5efbd05cc5a9f51a2549dcf)
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/mjpegdec.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/mjpegdec.c b/libavcodec/mjpegdec.c
index 97e0f12f44..27b0e5bff1 100644
--- a/libavcodec/mjpegdec.c
+++ b/libavcodec/mjpegdec.c
@@ -329,7 +329,7 @@ int ff_mjpeg_decode_sof(MJpegDecodeContext *s)
s->first_picture = 0;
}
- if (s->interlaced && (s->bottom_field == !s->interlace_polarity)) {
+ if (s->got_picture && s->interlaced && (s->bottom_field == !s->interlace_polarity)) {
if (s->progressive) {
av_log_ask_for_sample(s->avctx, "progressively coded interlaced pictures not supported\n");
return AVERROR_INVALIDDATA;