[FFmpeg-cvslog] gifdec: reset previous Graphic Control Extension disposal type

Michael Niedermayer git at videolan.org
Tue May 7 17:03:53 CEST 2013


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Tue May  7 16:07:27 2013 +0200| [d23b8462b5a4a9da78ed45c4a7a3b35d538df909] | committer: Michael Niedermayer

gifdec: reset previous Graphic Control Extension disposal type

This fixes out of array accesses.

Found-by: Mateusz "j00ru" Jurczyk and Gynvael Coldwind
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

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

 libavcodec/gifdec.c |    1 +
 1 file changed, 1 insertion(+)

diff --git a/libavcodec/gifdec.c b/libavcodec/gifdec.c
index 997bd42..5ca82e3 100644
--- a/libavcodec/gifdec.c
+++ b/libavcodec/gifdec.c
@@ -461,6 +461,7 @@ static int gif_decode_frame(AVCodecContext *avctx, void *data, int *got_frame, A
 
     if (s->keyframe) {
         s->keyframe_ok = 0;
+        s->gce_prev_disposal = GCE_DISPOSAL_NONE;
         if ((ret = gif_read_header1(s)) < 0)
             return ret;
 



More information about the ffmpeg-cvslog mailing list