aboutsummaryrefslogtreecommitdiffstats
path: root/src/input/DespotifyInputPlugin.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2013-01-21 18:24:26 +0100
committerMax Kellermann <max@duempel.org>2013-01-21 19:01:10 +0100
commit9ec069104f82184fbdc33bb82ead393441a41728 (patch)
treed887d486682b9f3916f84032d08812954d6b9aeb /src/input/DespotifyInputPlugin.cxx
parent7d21d60dbaefa90a2d52636766f7d060cb1cf481 (diff)
downloadmpd-9ec069104f82184fbdc33bb82ead393441a41728.tar.gz
mpd-9ec069104f82184fbdc33bb82ead393441a41728.tar.xz
mpd-9ec069104f82184fbdc33bb82ead393441a41728.zip
input,playlist/despotify: convert to C++
Diffstat (limited to '')
-rw-r--r--src/input/DespotifyInputPlugin.cxx (renamed from src/input/despotify_input_plugin.c)28
1 files changed, 18 insertions, 10 deletions
diff --git a/src/input/despotify_input_plugin.c b/src/input/DespotifyInputPlugin.cxx
index 200a0afd6..b42979e3b 100644
--- a/src/input/despotify_input_plugin.c
+++ b/src/input/DespotifyInputPlugin.cxx
@@ -1,5 +1,5 @@
/*
- * Copyright (C) 2011 The Music Player Daemon Project
+ * Copyright (C) 2011-2013 The Music Player Daemon Project
* http://www.musicpd.org
*
* This program is free software; you can redistribute it and/or modify
@@ -18,18 +18,21 @@
*/
#include "config.h"
-#include "input/despotify_input_plugin.h"
+#include "DespotifyInputPlugin.hxx"
+#include "DespotifyUtils.hxx"
#include "input_internal.h"
#include "input_plugin.h"
#include "tag.h"
-#include "despotify_utils.h"
+
+extern "C" {
+#include <despotify.h>
+}
#include <glib.h>
#include <unistd.h>
#include <string.h>
#include <errno.h>
-#include <despotify.h>
#include <stdio.h>
@@ -220,11 +223,16 @@ input_despotify_tag(struct input_stream *is)
}
const struct input_plugin input_plugin_despotify = {
- .name = "spt",
- .open = input_despotify_open,
- .close = input_despotify_close,
- .read = input_despotify_read,
- .eof = input_despotify_eof,
- .seek = input_despotify_seek,
+ "spt",
+ nullptr,
+ nullptr,
+ input_despotify_open,
+ input_despotify_close,
+ nullptr,
+ nullptr,
.tag = input_despotify_tag,
+ nullptr,
+ input_despotify_read,
+ input_despotify_eof,
+ input_despotify_seek,
};