changeset 226:514c7adecf39 trunk

[svn] - only penalize for bad frames on fixed streams
author nenolod
date Sun, 05 Nov 2006 13:14:06 -0800
parents 6a512dedcfbe
children fd4cba2fe99b
files ChangeLog src/mpg123/common.c
diffstat 2 files changed, 10 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog	Sun Nov 05 13:00:47 2006 -0800
+++ b/ChangeLog	Sun Nov 05 13:14:06 2006 -0800
@@ -1,3 +1,11 @@
+2006-11-05 21:00:47 +0000  William Pitcock <nenolod@nenolod.net>
+  revision [450]
+  - set mpgdec_length to -1 on a stream with no endpoint
+  
+  trunk/src/mpg123/mpg123.c |    3 ++-
+  1 file changed, 2 insertions(+), 1 deletion(-)
+
+
 2006-11-05 20:50:07 +0000  William Pitcock <nenolod@nenolod.net>
   revision [448]
   - shoutcast streams don't have a length.
--- a/src/mpg123/common.c	Sun Nov 05 13:00:47 2006 -0800
+++ b/src/mpg123/common.c	Sun Nov 05 13:14:06 2006 -0800
@@ -300,7 +300,8 @@
 	if (try >= 0)
 	    g_log("mpgdec", G_LOG_LEVEL_WARNING, "mpgdec: illegal bitstream in the middle of the MPEG stream, skipped %d bytes", try);
 #endif
-        mpgdec_info->filesize -= try;
+        if (mpgdec_info->filesize > 0)
+            mpgdec_info->filesize -= try;
     }
     /* flip/init buffer for Layer 3 */
     bsbufold = bsbuf;