[Ffmpeg-cvslog] CVS: ffmpeg/libavcodec huffyuv.c,1.67,1.68

Michael Niedermayer CVS michael
Sat Mar 18 03:30:00 CET 2006


Update of /cvsroot/ffmpeg/ffmpeg/libavcodec
In directory mail:/var2/tmp/cvs-serv16015

Modified Files:
	huffyuv.c 
Log Message:
segfault fix


Index: huffyuv.c
===================================================================
RCS file: /cvsroot/ffmpeg/ffmpeg/libavcodec/huffyuv.c,v
retrieving revision 1.67
retrieving revision 1.68
diff -u -d -r1.67 -r1.68
--- huffyuv.c	8 Mar 2006 11:43:08 -0000	1.67
+++ huffyuv.c	18 Mar 2006 02:29:58 -0000	1.68
@@ -808,6 +808,9 @@
             return -1;
     }
 
+    if((unsigned)(buf_size-table_size) >= INT_MAX/8)
+        return -1;
+
     init_get_bits(&s->gb, s->bitstream_buffer+table_size, (buf_size-table_size)*8);
 
     fake_ystride= s->interlaced ? p->linesize[0]*2  : p->linesize[0];





More information about the ffmpeg-cvslog mailing list