100l: forgot to reset LS mode on new frame
authorKostya Shishkov <kostya.shishkov@gmail.com>
Wed, 21 Feb 2007 18:10:25 +0000 (18:10 +0000)
committerKostya Shishkov <kostya.shishkov@gmail.com>
Wed, 21 Feb 2007 18:10:25 +0000 (18:10 +0000)
Originally committed as revision 8053 to svn://svn.ffmpeg.org/ffmpeg/trunk

libavcodec/mjpeg.c

index 6940e0d85572fbf39ef682c5b82c88b7b5f0c04b..e13e12cc842126909ff5000e596c7a326a58c8e0 100644 (file)
@@ -2128,18 +2128,21 @@ static int mjpeg_decode_frame(AVCodecContext *avctx,
                     break;
                 case SOF0:
                     s->lossless=0;
+                    s->ls=0;
                     s->progressive=0;
                     if (mjpeg_decode_sof(s) < 0)
                         return -1;
                     break;
                 case SOF2:
                     s->lossless=0;
+                    s->ls=0;
                     s->progressive=1;
                     if (mjpeg_decode_sof(s) < 0)
                         return -1;
                     break;
                 case SOF3:
                     s->lossless=1;
+                    s->ls=0;
                     s->progressive=0;
                     if (mjpeg_decode_sof(s) < 0)
                         return -1;