1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

avcodec/mjpegdec: Dont skip picture allocation if theres no picture allocated

Fixes Ticket 3245
This commit is contained in:
Michael Niedermayer 2014-01-19 16:44:58 +01:00
parent 5607242155
commit ad8d063f23

View File

@ -336,7 +336,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) {
avpriv_request_sample(s->avctx, "progressively coded interlaced picture");
return AVERROR_INVALIDDATA;