[Ffmpeg-cvslog] CVS: ffmpeg/libavcodec h264.c,1.154,1.155

Reimar Döffinger CVS reimar
Sat Sep 17 10:15:10 CEST 2005


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

Modified Files:
	h264.c 
Log Message:
check return value of decode_cabac_mb_dqp, it is INT_MIN on error.
fixes crash with http://stud4.tuwien.ac.at/~e0326863/ats/bbc-sample_small.mpg
and MPlayer's broken packetizer (but will not decode right of course).


Index: h264.c
===================================================================
RCS file: /cvsroot/ffmpeg/ffmpeg/libavcodec/h264.c,v
retrieving revision 1.154
retrieving revision 1.155
diff -u -d -r1.154 -r1.155
--- h264.c	10 Sep 2005 01:13:10 -0000	1.154
+++ h264.c	17 Sep 2005 08:15:07 -0000	1.155
@@ -6044,6 +6044,10 @@
         }
 
         h->last_qscale_diff = dqp = decode_cabac_mb_dqp( h );
+        if( dqp == INT_MIN ){
+            av_log(h->s.avctx, AV_LOG_ERROR, "cabac decode of qscale diff failed at %d %d\n", s->mb_x, s->mb_y);
+            return -1;
+        }
         s->qscale += dqp;
         if(((unsigned)s->qscale) > 51){
             if(s->qscale<0) s->qscale+= 52;





More information about the ffmpeg-cvslog mailing list