[MPlayer-cvslog] r31206 - trunk/libmpcodecs/vd_theora.c

reimar subversion at mplayerhq.hu
Mon May 24 01:24:26 CEST 2010


Author: reimar
Date: Mon May 24 01:24:25 2010
New Revision: 31206

Log:
Avoid decoding of 0-size packets. This also fixes that the main loop believes
tehre is an infinite number of delayed frames, thus never finishing (happens
with -demuxer lavf -vc theora).

Modified:
   trunk/libmpcodecs/vd_theora.c

Modified: trunk/libmpcodecs/vd_theora.c
==============================================================================
--- trunk/libmpcodecs/vd_theora.c	Mon May 24 01:22:25 2010	(r31205)
+++ trunk/libmpcodecs/vd_theora.c	Mon May 24 01:24:25 2010	(r31206)
@@ -168,6 +168,10 @@ static mp_image_t* decode(sh_video_t *sh
    yuv_buffer yuv;
    mp_image_t* mpi;
 
+   // no delayed frames
+   if (!data || !len)
+       return NULL;
+
    memset (&op, 0, sizeof (op));
    op.bytes = len;
    op.packet = data;


More information about the MPlayer-cvslog mailing list