[xiph-commits] r10864 - in icecast/branches/kh/icecast: admin src

karl at svn.xiph.org karl at svn.xiph.org
Tue Feb 21 17:06:48 PST 2006


Author: karl
Date: 2006-02-21 17:06:43 -0800 (Tue, 21 Feb 2006)
New Revision: 10864

Modified:
   icecast/branches/kh/icecast/admin/stats.xsl
   icecast/branches/kh/icecast/src/format.c
   icecast/branches/kh/icecast/src/slave.c
   icecast/branches/kh/icecast/src/source.c
   icecast/branches/kh/icecast/src/stats.c
Log:
fix race condition in relay handling, add other minor changes for debug


Modified: icecast/branches/kh/icecast/admin/stats.xsl
===================================================================
--- icecast/branches/kh/icecast/admin/stats.xsl	2006-02-21 23:09:19 UTC (rev 10863)
+++ icecast/branches/kh/icecast/admin/stats.xsl	2006-02-22 01:06:43 UTC (rev 10864)
@@ -62,7 +62,6 @@
 
 <!--mount point stats-->
 <xsl:for-each select="source">
-<xsl:if test = "listeners!=''"> 
 <div class="roundcont">
 <div class="roundtop">
 <img src="/images/corner_topleft.jpg" class="corner" style="display: none" />
@@ -110,7 +109,6 @@
 </div>
 <br />
 <br />
-</xsl:if>
 </xsl:for-each>
 <xsl:text disable-output-escaping="yes">&amp;</xsl:text>nbsp;
 

Modified: icecast/branches/kh/icecast/src/format.c
===================================================================
--- icecast/branches/kh/icecast/src/format.c	2006-02-21 23:09:19 UTC (rev 10863)
+++ icecast/branches/kh/icecast/src/format.c	2006-02-22 01:06:43 UTC (rev 10864)
@@ -111,12 +111,11 @@
         refbuf = source->stream_data_tail;
     else
     {
-        long size = 0;
+        long size = client->intro_offset;
         refbuf = source->burst_point;
-        size = client->intro_offset;
         while (size > 0 && refbuf->next)
         {
-            size -= refbuf->len;
+            size -= (long)refbuf->len;
             refbuf = refbuf->next;
         }
     }

Modified: icecast/branches/kh/icecast/src/slave.c
===================================================================
--- icecast/branches/kh/icecast/src/slave.c	2006-02-21 23:09:19 UTC (rev 10863)
+++ icecast/branches/kh/icecast/src/slave.c	2006-02-22 01:06:43 UTC (rev 10864)
@@ -386,7 +386,7 @@
         if (relay->source)
         {
             DEBUG1("Adding relay source at mountpoint \"%s\"", relay->localmount);
-            relay->cleanup = 1;
+            slave_rebuild_mounts();
         }
         else
             WARN1 ("new relay but source \"%s\" already exists", relay->localmount);

Modified: icecast/branches/kh/icecast/src/source.c
===================================================================
--- icecast/branches/kh/icecast/src/source.c	2006-02-21 23:09:19 UTC (rev 10863)
+++ icecast/branches/kh/icecast/src/source.c	2006-02-22 01:06:43 UTC (rev 10864)
@@ -352,7 +352,7 @@
             }
         }
 
-        /* we need to move the client and pending trees */
+        /* we need to move the active listeners */
         while (source->active_clients)
         {
             client_t *client = source->active_clients;

Modified: icecast/branches/kh/icecast/src/stats.c
===================================================================
--- icecast/branches/kh/icecast/src/stats.c	2006-02-21 23:09:19 UTC (rev 10863)
+++ icecast/branches/kh/icecast/src/stats.c	2006-02-22 01:06:43 UTC (rev 10864)
@@ -489,7 +489,7 @@
             /* adding node */
             if (event->value)
             {
-                DEBUG2 ("new node %s (%s)", event->name, event->value);
+                DEBUG3 ("new node on %s \"%s\" (%s)", event->source, event->name, event->value);
                 node = (stats_node_t *)calloc(1,sizeof(stats_node_t));
                 node->name = (char *)strdup(event->name);
                 node->value = (char *)strdup(event->value);



More information about the commits mailing list