aboutsummaryrefslogtreecommitdiffstats
path: root/src/output
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-10-19 16:58:45 +0200
committerMax Kellermann <max@duempel.org>2013-10-19 17:24:21 +0200
commit5dc4cbdf82191bc29afc414ac10204bd17275d69 (patch)
tree76ad2e5c60de0e3f504a84cd1d6cff912153adbf /src/output
parent1434e5a22e82b4176c24c536a91eefa183b78516 (diff)
downloadmpd-5dc4cbdf82191bc29afc414ac10204bd17275d69.tar.gz
mpd-5dc4cbdf82191bc29afc414ac10204bd17275d69.tar.xz
mpd-5dc4cbdf82191bc29afc414ac10204bd17275d69.zip
util/FormatString: new library to replace g_strdup_printf()
Diffstat (limited to 'src/output')
-rw-r--r--src/output/HttpdClient.cxx6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/output/HttpdClient.cxx b/src/output/HttpdClient.cxx
index c622f823a..9595e47f6 100644
--- a/src/output/HttpdClient.cxx
+++ b/src/output/HttpdClient.cxx
@@ -146,9 +146,7 @@ HttpdClient::SendResponse()
httpd->content_type);
} else if (metadata_requested) {
- gchar *metadata_header;
-
- metadata_header =
+ char *metadata_header =
icy_server_metadata_header(httpd->name, httpd->genre,
httpd->website,
httpd->content_type,
@@ -156,7 +154,7 @@ HttpdClient::SendResponse()
g_strlcpy(buffer, metadata_header, sizeof(buffer));
- g_free(metadata_header);
+ delete[] metadata_header;
} else { /* revert to a normal HTTP request */
snprintf(buffer, sizeof(buffer),