[xiph-cvs] cvs commit: vorbis-tools/ogg123 ogg123.c

Stan Seibert volsung at xiph.org
Mon Sep 1 15:50:33 PDT 2003



volsung     03/09/01 18:50:33

  Modified:    ogg123   ogg123.c
  Log:
  Bail out if seeking fails.

Revision  Changes    Path
1.68      +6 -2      vorbis-tools/ogg123/ogg123.c

Index: ogg123.c
===================================================================
RCS file: /usr/local/cvsroot/vorbis-tools/ogg123/ogg123.c,v
retrieving revision 1.67
retrieving revision 1.68
diff -u -r1.67 -r1.68
--- ogg123.c	1 Sep 2003 20:02:58 -0000	1.67
+++ ogg123.c	1 Sep 2003 22:50:32 -0000	1.68
@@ -14,7 +14,7 @@
  *                                                                  *
  ********************************************************************
 
- last mod: $Id: ogg123.c,v 1.67 2003/09/01 20:02:58 volsung Exp $
+ last mod: $Id: ogg123.c,v 1.68 2003/09/01 22:50:32 volsung Exp $
 
  ********************************************************************/
 
@@ -473,8 +473,12 @@
 
   /* Skip over audio */
   if (options.seekpos > 0.0) {
-    if (!format->seek(decoder, options.seekpos, DECODER_SEEK_START))
+    if (!format->seek(decoder, options.seekpos, DECODER_SEEK_START)) {
       status_error(_("Could not skip %f seconds of audio."), options.seekpos);
+      if (audio_buffer != NULL)
+	buffer_thread_kill(audio_buffer);
+      return;
+    }
   }
 
   /* Main loop:  Iterates over all of the logical bitstreams in the file */

<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