Commit dcbc05a9 authored by Max Kellermann's avatar Max Kellermann

output/httpd: import GetEventLoop()

parent 4c705334
...@@ -164,6 +164,8 @@ public: ...@@ -164,6 +164,8 @@ public:
#pragma GCC diagnostic pop #pragma GCC diagnostic pop
#endif #endif
using DeferredMonitor::GetEventLoop;
bool Init(const config_param &param, Error &error); bool Init(const config_param &param, Error &error);
void Finish() { void Finish() {
......
...@@ -72,7 +72,7 @@ HttpdOutput::Bind(Error &error) ...@@ -72,7 +72,7 @@ HttpdOutput::Bind(Error &error)
open = false; open = false;
bool result = false; bool result = false;
BlockingCall(DeferredMonitor::GetEventLoop(), [this, &error, &result](){ BlockingCall(GetEventLoop(), [this, &error, &result](){
result = ServerSocket::Open(error); result = ServerSocket::Open(error);
}); });
return result; return result;
...@@ -83,7 +83,7 @@ HttpdOutput::Unbind() ...@@ -83,7 +83,7 @@ HttpdOutput::Unbind()
{ {
assert(!open); assert(!open);
BlockingCall(DeferredMonitor::GetEventLoop(), [this](){ BlockingCall(GetEventLoop(), [this](){
ServerSocket::Close(); ServerSocket::Close();
}); });
} }
...@@ -167,7 +167,7 @@ httpd_output_finish(struct audio_output *ao) ...@@ -167,7 +167,7 @@ httpd_output_finish(struct audio_output *ao)
inline void inline void
HttpdOutput::AddClient(int fd) HttpdOutput::AddClient(int fd)
{ {
clients.emplace_front(*this, fd, ServerSocket::GetEventLoop(), clients.emplace_front(*this, fd, GetEventLoop(),
encoder->plugin.tag == nullptr); encoder->plugin.tag == nullptr);
++clients_cnt; ++clients_cnt;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment