[Icecast-dev] Possible Minor bug found in current 2.3.1 release of icecast2

Leif Jackson ljackson at bigirondata.net
Sat Jul 22 22:27:53 PDT 2006


I am new to your lists but I have found something in icecast 2.3.1 that
may need further review. there is a segfault when you have a failover
mount point and the failover mount is using ezstream and you restart
ices-2.x and the clients fail back. found via gdb. Very short diff to
format.c line 104 below.

diff -urNab icecast-2.3.1.orig/src/format.c icecast-2.3.1/src/format.c
--- icecast-2.3.1.orig/src/format.c     2006-07-23 00:48:16.418444051 -0400
+++ icecast-2.3.1/src/format.c  2006-07-20 22:38:30.000000000 -0400
@@ -101,7 +101,7 @@
         long size = 0;
         refbuf = source->burst_point;
         size = client->intro_offset;
-        while ((size > 0) && refbuf->next)
+        while ((size > 0) && (refbuf != NULL) && refbuf->next)
         {
             size -= refbuf->len;
             refbuf = refbuf->next;


This fixed the segfaulting issue for me, wanted to send it to the devel list.

Thanks,
Leif




More information about the Icecast-dev mailing list