diff options
author | Max Kellermann <max@duempel.org> | 2013-01-10 10:15:09 +0100 |
---|---|---|
committer | Max Kellermann <max@duempel.org> | 2013-01-10 10:15:09 +0100 |
commit | d5516dee005075a7569890c0cea4235659687ea1 (patch) | |
tree | 969046fc869f266103afc06bd2e8e1bd9c201d33 /src | |
parent | 06e0741a5293b1db2ef5f2b5778e3669f2dea70e (diff) | |
download | mpd-d5516dee005075a7569890c0cea4235659687ea1.tar.gz mpd-d5516dee005075a7569890c0cea4235659687ea1.tar.xz mpd-d5516dee005075a7569890c0cea4235659687ea1.zip |
input_stream: convert to C++ (internally)
Diffstat (limited to 'src')
-rw-r--r-- | src/CommandLine.cxx | 2 | ||||
-rw-r--r-- | src/InputInit.cxx (renamed from src/input_init.c) | 6 | ||||
-rw-r--r-- | src/InputInit.hxx (renamed from src/input_init.h) | 8 | ||||
-rw-r--r-- | src/InputRegistry.cxx (renamed from src/input_registry.c) | 4 | ||||
-rw-r--r-- | src/InputRegistry.hxx (renamed from src/input_registry.h) | 8 | ||||
-rw-r--r-- | src/InputStream.cxx (renamed from src/input_stream.c) | 7 | ||||
-rw-r--r-- | src/Main.cxx | 2 |
7 files changed, 18 insertions, 19 deletions
diff --git a/src/CommandLine.cxx b/src/CommandLine.cxx index 6f9528a4e..a8608af9c 100644 --- a/src/CommandLine.cxx +++ b/src/CommandLine.cxx @@ -27,7 +27,7 @@ #include "decoder_plugin.h" #include "OutputList.hxx" #include "output_plugin.h" -#include "input_registry.h" +#include "InputRegistry.hxx" #include "input_plugin.h" #include "playlist_list.h" #include "playlist_plugin.h" diff --git a/src/input_init.c b/src/InputInit.cxx index 771d648d1..6714cc727 100644 --- a/src/input_init.c +++ b/src/InputInit.cxx @@ -1,5 +1,5 @@ /* - * Copyright (C) 2003-2011 The Music Player Daemon Project + * Copyright (C) 2003-2013 The Music Player Daemon Project * http://www.musicpd.org * * This program is free software; you can redistribute it and/or modify @@ -18,9 +18,9 @@ */ #include "config.h" -#include "input_init.h" +#include "InputInit.hxx" +#include "InputRegistry.hxx" #include "input_plugin.h" -#include "input_registry.h" #include "conf.h" #include <assert.h> diff --git a/src/input_init.h b/src/InputInit.hxx index 1a73e5ef9..9d503e5a8 100644 --- a/src/input_init.h +++ b/src/InputInit.hxx @@ -1,5 +1,5 @@ /* - * Copyright (C) 2003-2011 The Music Player Daemon Project + * Copyright (C) 2003-2013 The Music Player Daemon Project * http://www.musicpd.org * * This program is free software; you can redistribute it and/or modify @@ -17,13 +17,11 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ -#ifndef MPD_INPUT_INIT_H -#define MPD_INPUT_INIT_H +#ifndef MPD_INPUT_INIT_HXX +#define MPD_INPUT_INIT_HXX #include "gerror.h" -#include <stdbool.h> - /** * Initializes this library and all input_stream implementations. * diff --git a/src/input_registry.c b/src/InputRegistry.cxx index 5987d5da2..ef8fe5dfd 100644 --- a/src/input_registry.c +++ b/src/InputRegistry.cxx @@ -1,5 +1,5 @@ /* - * Copyright (C) 2003-2011 The Music Player Daemon Project + * Copyright (C) 2003-2013 The Music Player Daemon Project * http://www.musicpd.org * * This program is free software; you can redistribute it and/or modify @@ -18,7 +18,7 @@ */ #include "config.h" -#include "input_registry.h" +#include "InputRegistry.hxx" #include "input/file_input_plugin.h" #ifdef ENABLE_ARCHIVE diff --git a/src/input_registry.h b/src/InputRegistry.hxx index 4f5fff8da..a080d108b 100644 --- a/src/input_registry.h +++ b/src/InputRegistry.hxx @@ -1,5 +1,5 @@ /* - * Copyright (C) 2003-2011 The Music Player Daemon Project + * Copyright (C) 2003-2013 The Music Player Daemon Project * http://www.musicpd.org * * This program is free software; you can redistribute it and/or modify @@ -17,13 +17,11 @@ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. */ -#ifndef MPD_INPUT_REGISTRY_H -#define MPD_INPUT_REGISTRY_H +#ifndef MPD_INPUT_REGISTRY_HXX +#define MPD_INPUT_REGISTRY_HXX #include "check.h" -#include <stdbool.h> - /** * NULL terminated list of all input plugins which were enabled at * compile time. diff --git a/src/input_stream.c b/src/InputStream.cxx index c82788f39..64f347555 100644 --- a/src/input_stream.c +++ b/src/InputStream.cxx @@ -19,10 +19,13 @@ #include "config.h" #include "input_stream.h" -#include "input_registry.h" +#include "InputRegistry.hxx" #include "input_plugin.h" + +extern "C" { #include "input/rewind_input_plugin.h" #include "uri.h" +} #include <glib.h> #include <assert.h> @@ -172,7 +175,7 @@ input_stream_lock_tag(struct input_stream *is) assert(is->plugin != NULL); if (is->plugin->tag == NULL) - return false; + return nullptr; if (is->mutex == NULL) /* no locking */ diff --git a/src/Main.cxx b/src/Main.cxx index bece3720c..d091b9641 100644 --- a/src/Main.cxx +++ b/src/Main.cxx @@ -44,6 +44,7 @@ #include "SignalHandlers.hxx" #include "Log.hxx" #include "GlobalEvents.hxx" +#include "InputInit.hxx" extern "C" { #include "daemon.h" @@ -53,7 +54,6 @@ extern "C" { #include "audio_config.h" #include "pcm_resample.h" #include "decoder_list.h" -#include "input_init.h" #include "playlist_list.h" #include "zeroconf.h" } |