[xiph-commits] r14511 - trunk/speex/src

gmaxwell at svn.xiph.org gmaxwell at svn.xiph.org
Thu Feb 14 12:54:43 PST 2008


Author: gmaxwell
Date: 2008-02-14 12:54:42 -0800 (Thu, 14 Feb 2008)
New Revision: 14511

Modified:
   trunk/speex/src/speexdec.c
Log:
Fix for fuzz testing found bug: Handle zero byte packets from libogg correctly.



Modified: trunk/speex/src/speexdec.c
===================================================================
--- trunk/speex/src/speexdec.c	2008-02-14 15:56:39 UTC (rev 14510)
+++ trunk/speex/src/speexdec.c	2008-02-14 20:54:42 UTC (rev 14511)
@@ -639,7 +639,7 @@
          last_granule = page_granule;
          /*Extract all available packets*/
          packet_no=0;
-         while (!eos && ogg_stream_packetout(&os, &op) == 1)
+         while (!eos && ogg_stream_packetout(&os, &op) == 1 && op.bytes>=5)
          {
 	    if (!memcmp(op.packet, "Speex", 5)) {
 	       speex_serialno = os.serialno;



More information about the commits mailing list