output/httpd: import GetEventLoop()
This commit is contained in:
parent
4c705334fa
commit
dcbc05a9cd
@ -164,6 +164,8 @@ public:
|
|||||||
#pragma GCC diagnostic pop
|
#pragma GCC diagnostic pop
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
using DeferredMonitor::GetEventLoop;
|
||||||
|
|
||||||
bool Init(const config_param ¶m, Error &error);
|
bool Init(const config_param ¶m, Error &error);
|
||||||
|
|
||||||
void Finish() {
|
void Finish() {
|
||||||
|
@ -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()
|
|||||||
{
|
{
|
||||||
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)
|
|||||||
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;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user