aboutsummaryrefslogtreecommitdiffstats
path: root/src/output
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-07-30 20:11:57 +0200
committerMax Kellermann <max@duempel.org>2013-07-30 20:19:53 +0200
commit06f898cc1240a29b293de0e97ad95a4fdc971254 (patch)
tree001a6d3db039cdc03323f3bfddc13b94bde31ce4 /src/output
parent6a9ab8bc0e2f5d34803513bb2d94d041a607a58c (diff)
downloadmpd-06f898cc1240a29b293de0e97ad95a4fdc971254.tar.gz
mpd-06f898cc1240a29b293de0e97ad95a4fdc971254.tar.xz
mpd-06f898cc1240a29b293de0e97ad95a4fdc971254.zip
tag: convert to C++
Diffstat (limited to 'src/output')
-rw-r--r--src/output/AoOutputPlugin.cxx2
-rw-r--r--src/output/HttpdInternal.hxx3
-rw-r--r--src/output/HttpdOutputPlugin.cxx7
-rw-r--r--src/output/JackOutputPlugin.cxx1
-rw-r--r--src/output/RoarOutputPlugin.cxx2
-rw-r--r--src/output/ShoutOutputPlugin.cxx5
6 files changed, 13 insertions, 7 deletions
diff --git a/src/output/AoOutputPlugin.cxx b/src/output/AoOutputPlugin.cxx
index 85f0ca5cb..b534ddf08 100644
--- a/src/output/AoOutputPlugin.cxx
+++ b/src/output/AoOutputPlugin.cxx
@@ -24,6 +24,8 @@
#include <ao/ao.h>
#include <glib.h>
+#include <string.h>
+
#undef G_LOG_DOMAIN
#define G_LOG_DOMAIN "ao"
diff --git a/src/output/HttpdInternal.hxx b/src/output/HttpdInternal.hxx
index d7394d051..c2ac96be5 100644
--- a/src/output/HttpdInternal.hxx
+++ b/src/output/HttpdInternal.hxx
@@ -38,6 +38,7 @@ class ServerSocket;
class HttpdClient;
class Page;
struct Encoder;
+struct Tag;
struct HttpdOutput final : private ServerSocket {
struct audio_output base;
@@ -195,7 +196,7 @@ struct HttpdOutput final : private ServerSocket {
bool EncodeAndPlay(const void *chunk, size_t size, GError **error_r);
- void SendTag(const struct tag *tag);
+ void SendTag(const Tag *tag);
private:
virtual void OnAccept(int fd, const sockaddr &address,
diff --git a/src/output/HttpdOutputPlugin.cxx b/src/output/HttpdOutputPlugin.cxx
index 2ac462842..36bd1aee1 100644
--- a/src/output/HttpdOutputPlugin.cxx
+++ b/src/output/HttpdOutputPlugin.cxx
@@ -34,6 +34,7 @@
#include <sys/types.h>
#include <unistd.h>
+#include <string.h>
#include <errno.h>
#ifdef HAVE_LIBWRAP
@@ -484,7 +485,7 @@ httpd_output_pause(struct audio_output *ao)
}
inline void
-HttpdOutput::SendTag(const struct tag *tag)
+HttpdOutput::SendTag(const Tag *tag)
{
assert(tag != NULL);
@@ -523,7 +524,7 @@ HttpdOutput::SendTag(const struct tag *tag)
TAG_NUM_OF_ITEM_TYPES
};
- metadata = icy_server_metadata_page(tag, &types[0]);
+ metadata = icy_server_metadata_page(*tag, &types[0]);
if (metadata != NULL) {
const ScopeLock protect(mutex);
for (auto &client : clients)
@@ -533,7 +534,7 @@ HttpdOutput::SendTag(const struct tag *tag)
}
static void
-httpd_output_tag(struct audio_output *ao, const struct tag *tag)
+httpd_output_tag(struct audio_output *ao, const Tag *tag)
{
HttpdOutput *httpd = Cast(ao);
diff --git a/src/output/JackOutputPlugin.cxx b/src/output/JackOutputPlugin.cxx
index c32fb914b..3bc9cee8f 100644
--- a/src/output/JackOutputPlugin.cxx
+++ b/src/output/JackOutputPlugin.cxx
@@ -29,6 +29,7 @@
#include <jack/ringbuffer.h>
#include <stdlib.h>
+#include <string.h>
#include <stdio.h>
#include <sys/types.h>
#include <unistd.h>
diff --git a/src/output/RoarOutputPlugin.cxx b/src/output/RoarOutputPlugin.cxx
index 328ef3922..835c7cdd9 100644
--- a/src/output/RoarOutputPlugin.cxx
+++ b/src/output/RoarOutputPlugin.cxx
@@ -329,7 +329,7 @@ roar_tag_convert(enum tag_type type, bool *is_uuid)
}
static void
-roar_send_tag(struct audio_output *ao, const struct tag *meta)
+roar_send_tag(struct audio_output *ao, const Tag *meta)
{
RoarOutput *self = (RoarOutput *)ao;
diff --git a/src/output/ShoutOutputPlugin.cxx b/src/output/ShoutOutputPlugin.cxx
index 0a46d8bee..a0f75da1d 100644
--- a/src/output/ShoutOutputPlugin.cxx
+++ b/src/output/ShoutOutputPlugin.cxx
@@ -29,6 +29,7 @@
#include <assert.h>
#include <stdlib.h>
+#include <string.h>
#include <stdio.h>
#undef G_LOG_DOMAIN
@@ -482,7 +483,7 @@ my_shout_pause(struct audio_output *ao)
}
static void
-shout_tag_to_metadata(const struct tag *tag, char *dest, size_t size)
+shout_tag_to_metadata(const Tag *tag, char *dest, size_t size)
{
char artist[size];
char title[size];
@@ -508,7 +509,7 @@ shout_tag_to_metadata(const struct tag *tag, char *dest, size_t size)
}
static void my_shout_set_tag(struct audio_output *ao,
- const struct tag *tag)
+ const Tag *tag)
{
ShoutOutput *sd = (ShoutOutput *)ao;
GError *error = nullptr;