aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--src/output/httpd_client.c11
-rw-r--r--src/output/httpd_internal.h13
-rw-r--r--src/output/httpd_output_plugin.c6
3 files changed, 25 insertions, 5 deletions
diff --git a/src/output/httpd_client.c b/src/output/httpd_client.c
index fa14d1956..6bd095838 100644
--- a/src/output/httpd_client.c
+++ b/src/output/httpd_client.c
@@ -282,11 +282,12 @@ httpd_client_send_response(struct httpd_client *client)
} else {
gchar *metadata_header;
- metadata_header = icy_server_metadata_header("Add config information here!", /* TODO */
- "Add config information here!", /* TODO */
- "Add config information here!", /* TODO */
- client->httpd->content_type,
- client->metaint);
+ metadata_header = icy_server_metadata_header(
+ client->httpd->name,
+ client->httpd->genre,
+ client->httpd->website,
+ client->httpd->content_type,
+ client->metaint);
g_strlcpy(buffer, metadata_header, sizeof(buffer));
diff --git a/src/output/httpd_internal.h b/src/output/httpd_internal.h
index e77a2fe0f..55843e73f 100644
--- a/src/output/httpd_internal.h
+++ b/src/output/httpd_internal.h
@@ -99,6 +99,19 @@ struct httpd_output {
struct page *metadata;
/**
+ * The configured name.
+ */
+ char const *name;
+ /**
+ * The configured genre.
+ */
+ char const *genre;
+ /**
+ * The configured website address.
+ */
+ char const *website;
+
+ /**
* A linked list containing all clients which are currently
* connected.
*/
diff --git a/src/output/httpd_output_plugin.c b/src/output/httpd_output_plugin.c
index 0467a88c5..d61570557 100644
--- a/src/output/httpd_output_plugin.c
+++ b/src/output/httpd_output_plugin.c
@@ -111,6 +111,12 @@ httpd_output_init(G_GNUC_UNUSED const struct audio_format *audio_format,
struct sockaddr_in *sin;
/* read configuration */
+ httpd->name =
+ config_get_block_string(param, "name", "Set name in config");
+ httpd->genre =
+ config_get_block_string(param, "genre", "Set genre in config");
+ httpd->website =
+ config_get_block_string(param, "website", "Set website in config");
port = config_get_block_unsigned(param, "port", 8000);