[xiph-cvs] cvs commit: vorbis/lib vorbisfile.c

Monty xiphmont at xiph.org
Tue Sep 16 13:28:15 PDT 2003



xiphmont    03/09/16 16:28:14

  Modified:    lib      vorbisfile.c
  Log:
  I've been getting sloppy lately... didn;t run streaming tests against
  most recent vorbisfile state machine fix ebcause I thought it didn't
  affect non-seekable.  I was wrong, and the chnage broke things.
  
  This fixes non-seekable input and I actually ran all the basic tests
  (streaming, seekable, seeking, crosslapping and full chain tests)
  before this commit.
  
  Monty

Revision  Changes    Path
1.75      +6 -4      vorbis/lib/vorbisfile.c

Index: vorbisfile.c
===================================================================
RCS file: /usr/local/cvsroot/vorbis/lib/vorbisfile.c,v
retrieving revision 1.74
retrieving revision 1.75
diff -u -r1.74 -r1.75
--- vorbisfile.c	12 Sep 2003 18:30:16 -0000	1.74
+++ vorbisfile.c	16 Sep 2003 20:28:14 -0000	1.75
@@ -11,7 +11,7 @@
  ********************************************************************
 
  function: stdio-based convenience library for opening/seeking/decoding
- last mod: $Id: vorbisfile.c,v 1.74 2003/09/12 18:30:16 xiphmont Exp $
+ last mod: $Id: vorbisfile.c,v 1.75 2003/09/16 20:28:14 xiphmont Exp $
 
  ********************************************************************/
 
@@ -672,8 +672,8 @@
 }
 
 static int _ov_open2(OggVorbis_File *vf){
-  if(vf->ready_state < OPENED)
-    vf->ready_state=OPENED;
+  if(vf->ready_state != PARTOPEN) return OV_EINVAL;
+  vf->ready_state=OPENED;
   if(vf->seekable){
     int ret=_open_seekable2(vf);
     if(ret){
@@ -681,7 +681,9 @@
       ov_clear(vf);
     }
     return(ret);
-  }
+  }else
+    vf->ready_state=STREAMSET;
+
   return 0;
 }
 

<p><p>--- >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