[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

UPDATE: net/icecast (2.3.0 -> 2.3.1)



Hi,


another update to net/icecast, with lots of reliability fixes:

The attached patch empties patches/patch-src_connection_c, which should
be removed.

New features for 2.3.1

* new tag <logsize> in <logging> state the trigger size (in KB) for
cycling the log files.
* new tag <logarchive> in <logging> enable (1) if you want to use a
timestamp for an extension when cycling logs.

Fixes for 2.3.1

* Handling of certain shoutcast source clients is fixed, this typically
affected NSV source clients (patch-src_connection_c)
* A race in source shutdown when listeners are authenticated could lead
to server crash
* An audio glitch was possible in playback of vorbis streams when a new
logical stream started (eg metadata update).
* stats speedup. Processing large numbers of stats was slow. Typically
only seen when using lots of streams on the same server.
* 404 responses were being sent back in some places, now 403 is sent back.
* Auth URL now handles the authentication to scripts better.
    The order in which username/password are selected is
    1. url is http://user:pass_(_at_)_host:port/....
    2. <param name="username"> and <param name="password">
    3. with listener_add/remove, listener supplied username/password
       is used.
* A streams intro file can now be changed, using HUP, on active streams.
* mount without a name crashed the server
* Various documentation updates

Changes in the port

* improved and consistent snprintf() patches (that's how it should be
done now, right?)
* further cleanup in COMMENT and DESCR (nicer line wrapping in the latter)


Moritz


diff -urN --exclude=CVS /usr/ports/net/icecast/Makefile ./Makefile
--- /usr/ports/net/icecast/Makefile	Fri Dec  9 18:30:27 2005
+++ ./Makefile	Fri Dec  9 18:41:45 2005
@@ -1,8 +1,8 @@
 # $OpenBSD: Makefile,v 1.31 2005/10/21 15:59:54 naddy Exp $
 
-COMMENT=	"server for streaming Ogg Vorbis and MP3"
+COMMENT=	"server for streaming various media formats"
 
-DISTNAME=	icecast-2.3.0
+DISTNAME=	icecast-2.3.1
 CATEGORIES=	net audio
 
 HOMEPAGE=	http://www.icecast.org/
diff -urN --exclude=CVS /usr/ports/net/icecast/distinfo ./distinfo
--- /usr/ports/net/icecast/distinfo	Fri Dec  9 18:30:27 2005
+++ ./distinfo	Fri Dec  9 18:00:32 2005
@@ -1,4 +1,4 @@
-MD5 (icecast-2.3.0.tar.gz) = 35256fbc4a93571662af2ed18fbbfcc5
-RMD160 (icecast-2.3.0.tar.gz) = 59ffe3fa53ef20d4a31c2d9ac3b73d2edc064911
-SHA1 (icecast-2.3.0.tar.gz) = 9210403649d178591d5f750bc88896352480ccb8
-SIZE (icecast-2.3.0.tar.gz) = 1091422
+MD5 (icecast-2.3.1.tar.gz) = 2d80a249fa8529f82d018c6216108ea8
+RMD160 (icecast-2.3.1.tar.gz) = 394148f060daca979d49787530c4928558dd325c
+SHA1 (icecast-2.3.1.tar.gz) = e874ffc7dbed82a15889186a1cd3b7b7de3aba5d
+SIZE (icecast-2.3.1.tar.gz) = 1094154
diff -urN --exclude=CVS /usr/ports/net/icecast/patches/patch-src_connection_c ./patches/patch-src_connection_c
--- /usr/ports/net/icecast/patches/patch-src_connection_c	Fri Oct 21 17:59:54 2005
+++ ./patches/patch-src_connection_c	Thu Jan  1 01:00:00 1970
@@ -1,40 +0,0 @@
-$OpenBSD: patch-src_connection_c,v 1.1 2005/10/21 15:59:54 naddy Exp $
---- src/connection.c.orig	Mon Sep 26 22:54:02 2005
-+++ src/connection.c	Mon Sep 26 19:21:07 2005
-@@ -872,7 +872,7 @@ static void _handle_shoutcast_compatible
- 
-     if (node->shoutcast == 1)
-     {
--        char *source_password, *ptr;
-+        char *source_password, *ptr, *headers;
-         mount_proxy *mountinfo = config_find_mount (config, config->shoutcast_mount);
- 
-         if (mountinfo && mountinfo->password)
-@@ -883,8 +883,14 @@ static void _handle_shoutcast_compatible
- 
-         /* Get rid of trailing \r\n or \n after password */
-         ptr = strstr (client->refbuf->data, "\r\n");
--        if (ptr == NULL)
-+        if (ptr)
-+            headers = ptr+2;
-+        else
-+        {
-             ptr = strstr (client->refbuf->data, "\n");
-+            if (ptr)
-+                headers = ptr+1;
-+        }
- 
-         if (ptr == NULL)
-         {
-@@ -901,9 +907,9 @@ static void _handle_shoutcast_compatible
-             /* send this non-blocking but if there is only a partial write
-              * then leave to header timeout */
-             sock_write (client->con->sock, "OK2\r\n");
--            memset (client->refbuf->data, 0, client->refbuf->len);
-+            node->offset -= (headers - client->refbuf->data);
-+            memmove (client->refbuf->data, headers, node->offset+1);
-             node->shoutcast = 2;
--            node->offset = 0;
-             /* we've checked the password, now send it back for reading headers */
-             _add_request_queue (node);
-             free (source_password);
diff -urN --exclude=CVS /usr/ports/net/icecast/patches/patch-src_util_c ./patches/patch-src_util_c
--- /usr/ports/net/icecast/patches/patch-src_util_c	Fri Oct 21 17:59:54 2005
+++ ./patches/patch-src_util_c	Fri Dec  2 15:40:30 2005
@@ -16,7 +16,7 @@
 +    fullpath = malloc(pathlen);
 +    if (fullpath) {
 +        int ret = snprintf(fullpath, pathlen, "%s%s", webroot, uri);
-+        if (ret == -1 || ret >= pathlen) {
++        if (ret < 0 || ret >= pathlen) {
 +            WARN0("Error generating full path name in util_get_path_from_normalised_uri()");
 +            free(fullpath);
 +            fullpath = NULL;
@@ -46,7 +46,7 @@
              }
 -            sprintf(res, "%s", dict->key);
 +            ret = snprintf(res, buflen, "%s", dict->key);
-+            if (ret == -1 || ret >= buflen) {
++            if (ret < 0 || ret >= buflen) {
 +                free(res);
 +                return NULL;
 +            }
@@ -65,7 +65,7 @@
 -            sprintf(res + strlen(res), "%c%s", delim, dict->key);
 +                ret = snprintf(res + strlen(res), buflen - strlen(res),
 +                    "%c%s", delim, dict->key);
-+                if (ret == -1 || ret >= buflen - strlen(res)) {
++                if (ret < 0 || ret >= buflen - strlen(res)) {
 +                    free(res);
 +                    return NULL;
 +                }
@@ -92,7 +92,7 @@
 -        free(enc);
 +            reslen = strlen(res);
 +            ret = snprintf(res + reslen, buflen - reslen, "=%s", enc);
-+            if (ret == -1 || ret >= buflen - reslen) {
++            if (ret < 0 || ret >= buflen - reslen) {
 +                free(enc);
 +                free(res);
 +                return NULL;
diff -urN --exclude=CVS /usr/ports/net/icecast/patches/patch-src_yp_c ./patches/patch-src_yp_c
--- /usr/ports/net/icecast/patches/patch-src_yp_c	Fri Oct 21 17:59:54 2005
+++ ./patches/patch-src_yp_c	Fri Dec  9 18:21:22 2005
@@ -20,7 +20,7 @@
           {
 -             sprintf (song, "%s%s%s", artist, separator, title);
 +             ret = snprintf (song, len, "%s%s%s", artist, separator, title);
-+             if (ret == -1 || ret >= (signed)songlen)
++             if (ret < 0 || ret >= songlen)
 +                 ERROR0 ("snprintf() in do_yp_touch()");
               add_yp_info(yp, song, YP_CURRENT_SONG);
               stats_event (yp->mount, "yp_currently_playing", song);
diff -urN --exclude=CVS /usr/ports/net/icecast/pkg/DESCR ./pkg/DESCR
--- /usr/ports/net/icecast/pkg/DESCR	Fri Oct 21 17:59:54 2005
+++ ./pkg/DESCR	Fri Dec  9 18:46:54 2005
@@ -1,8 +1,9 @@
 Icecast is a streaming media server which currently supports Ogg-based
-streams like Vorbis, Speex, FLAC, Midi and Theora, as well as MP3 and various
-others (even NSV Shoutcast streams). It can be used to create an Internet
-radio station or a privately run jukebox and many things inbetween. It is very
-versatile and supports open standards for communication and interaction.
+streams like Vorbis, Speex, FLAC, Midi and Theora, as well as MP3 and
+various others (even NSV Shoutcast streams). It can be used to create
+an Internet radio station or a privately run jukebox and many things
+inbetween. It is very versatile and supports open standards for
+communication and interaction.
 
 Icecast v2 is a complete rewrite of the old Icecast streaming server.
 It was designed to be highly efficient and have low memory requirements.


Visit your host, monkey.org