[xiph-cvs] cvs commit: ogg/src framing.c

Monty xiphmont at xiph.org
Thu May 24 14:22:53 PDT 2001



xiphmont    01/05/24 14:22:52

  Modified:    src      framing.c
  Log:
  optimization when using peek as a packet detector

Revision  Changes    Path
1.14      +5 -1      ogg/src/framing.c

Index: framing.c
===================================================================
RCS file: /usr/local/cvsroot/ogg/src/framing.c,v
retrieving revision 1.13
retrieving revision 1.14
diff -u -r1.13 -r1.14
--- framing.c	2001/05/24 05:17:14	1.13
+++ framing.c	2001/05/24 21:22:52	1.14
@@ -12,7 +12,7 @@
 
  function: code raw [Vorbis] packets into framed OggSquish stream and
            decode Ogg streams back into raw packets
- last mod: $Id: framing.c,v 1.13 2001/05/24 05:17:14 xiphmont Exp $
+ last mod: $Id: framing.c,v 1.14 2001/05/24 21:22:52 xiphmont Exp $
 
  note: The CRC code is directly derived from public domain code by
  Ross Williams (ross at guest.adelaide.edu.au).  See docs/framing.html
@@ -783,6 +783,10 @@
     os->packetno++;
     return(-1);
   }
+
+  if(!op && !adv)return(1); /* just using peek as an inexpensive way
+                               to ask if there's a whole packet
+                               waiting */
 
   /* Gather the whole packet. We'll have no holes or a partial packet */
   {

--- >8 ----
List archives:  http://www.xiph.org/archives/
Ogg project homepage: http://www.xiph.org/ogg/
To unsubscribe from this list, send a message to 'cvs-request at xiph.org'
containing only the word 'unsubscribe' in the body.  No subject is needed.
Unsubscribe messages sent to the list will be ignored/filtered.



More information about the commits mailing list