[FFmpeg-cvslog] avcodec/mjpegdec: update cur_scan also for non-LS jpeg

Michael Niedermayer git at videolan.org
Sun Jan 19 15:00:16 CET 2014


ffmpeg | branch: release/1.1 | Michael Niedermayer <michaelni at gmx.at> | Sun Jan 19 04:55:01 2014 +0100| [3ae81880e1ea688e732f736f2008c6f3e4cfab18] | committer: Carl Eugen Hoyos

avcodec/mjpegdec: update cur_scan also for non-LS jpeg

This should make no difference but the variable will be used in a subsequent commit

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
(cherry picked from commit 8893f31e206358d933abe4a5227b5ae89f5f303d)

Conflicts:
	libavcodec/mjpegdec.c

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=3ae81880e1ea688e732f736f2008c6f3e4cfab18
---

 libavcodec/mjpegdec.c |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/libavcodec/mjpegdec.c b/libavcodec/mjpegdec.c
index 60d3b70..78f63fe 100644
--- a/libavcodec/mjpegdec.c
+++ b/libavcodec/mjpegdec.c
@@ -1596,8 +1596,6 @@ int ff_mjpeg_find_marker(MJpegDecodeContext *s,
         int t = 0, b = 0;
         PutBitContext pb;
 
-        s->cur_scan++;
-
         /* find marker */
         while (src + t < buf_end) {
             uint8_t x = src[t++];
@@ -1783,6 +1781,7 @@ eoi_parser:
 
                 goto the_end;
             case SOS:
+                s->cur_scan++;
                 if ((ret = ff_mjpeg_decode_sos(s, NULL, NULL)) < 0 &&
                     (avctx->err_recognition & AV_EF_EXPLODE))
                     goto fail;



More information about the ffmpeg-cvslog mailing list