diff --git a/src/input/plugins/CurlInputPlugin.cxx b/src/input/plugins/CurlInputPlugin.cxx index e8d18ebe8..9fdae3f02 100644 --- a/src/input/plugins/CurlInputPlugin.cxx +++ b/src/input/plugins/CurlInputPlugin.cxx @@ -468,6 +468,14 @@ CurlInputStream::Open(const char *url, return std::make_unique(std::move(c), std::move(icy)); } +InputStreamPtr +OpenCurlInputStream(const char *uri, + const std::multimap &headers, + Mutex &mutex, Cond &cond) +{ + return CurlInputStream::Open(uri, headers, mutex, cond); +} + static InputStreamPtr input_curl_open(const char *url, Mutex &mutex, Cond &cond) { diff --git a/src/input/plugins/CurlInputPlugin.hxx b/src/input/plugins/CurlInputPlugin.hxx index bd57ca1a1..478acd43f 100644 --- a/src/input/plugins/CurlInputPlugin.hxx +++ b/src/input/plugins/CurlInputPlugin.hxx @@ -20,6 +20,26 @@ #ifndef MPD_INPUT_CURL_HXX #define MPD_INPUT_CURL_HXX +#include "input/Ptr.hxx" + +#include +#include + +class Mutex; +class Cond; + extern const struct InputPlugin input_plugin_curl; +/** + * Open a #CurlInputStream with custom request headers. + * + * This stream does not support Icy metadata. + * + * Throws on error. + */ +InputStreamPtr +OpenCurlInputStream(const char *uri, + const std::multimap &headers, + Mutex &mutex, Cond &cond); + #endif