Commit 82c9182f authored by Reimar Döffinger's avatar Reimar Döffinger

If the end of the input buffer is reached while decoding MJPEG and at least

a valid SOF was found, emulate an EOI.
This allows e.g. to at least decode the available part of incomplete MJPEG frames.

Originally committed as revision 19344 to svn://svn.ffmpeg.org/ffmpeg/trunk
parent 1496b04c
......@@ -1479,6 +1479,10 @@ not_the_end:
}
}
}
if (s->got_picture) {
av_log(avctx, AV_LOG_WARNING, "EOI missing, emulating\n");
goto eoi_parser;
}
av_log(avctx, AV_LOG_FATAL, "No JPEG data found in image\n");
return -1;
the_end:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment