From a2c849ed7c23b10d0e1dfd3df8b4e6b7b1e7f7e0 Mon Sep 17 00:00:00 2001 From: Karl Heyes Date: Fri, 17 Dec 2004 20:03:26 +0000 Subject: [PATCH] make recent YP updates follow agreed spec svn path=/icecast/trunk/icecast/; revision=8479 --- src/format_ogg.c | 2 +- src/yp.c | 11 +++++++++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/src/format_ogg.c b/src/format_ogg.c index e7ea0d27..b0cfaf75 100644 --- a/src/format_ogg.c +++ b/src/format_ogg.c @@ -285,7 +285,7 @@ static void update_comments (source_t *source) int len = strlen (codec_names); int remaining = sizeof (codec_names) - len; char *where = codec_names + len; - char *separator = " "; + char *separator = "/"; if (len == 0) separator = ""; snprintf (where, remaining, "%s%s", separator, codec->name); diff --git a/src/yp.c b/src/yp.c index 10907b53..756dd3d2 100644 --- a/src/yp.c +++ b/src/yp.c @@ -401,11 +401,18 @@ static unsigned do_yp_touch (ypdata_t *yp, char *s, unsigned len) free (max_listeners); max_listeners = (char *)stats_get_value (NULL, "client_limit"); } + val = stats_get_value (yp->mount, "subtype"); + if (val) + { + add_yp_info (yp, "subtype", val, YP_SUBTYPE); + free (val); + } ret = snprintf (s, len, "action=touch&sid=%s&st=%s" - "&listeners=%u&max_listeners=%s\r\n", - yp->sid, yp->current_song, listeners, max_listeners); + "&listeners=%u&max_listeners=%s&stype=%s\r\n", + yp->sid, yp->current_song, listeners, max_listeners, yp->subtype); + free (max_listeners); if (ret >= (signed)len) return ret+1; /* space required for above text and nul*/