X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fmodules%2Fm_httpd.cpp;h=b453a28056d0f0e9489ee3225115117f7b41f51c;hb=de69e28a4a1aea89e410b693bbbb67890ecb0bd3;hp=748f530ca9642d684dce916fc916ab1b59723d1c;hpb=b43fc66c17c2bef6dca66a966676b8128d5774ee;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/modules/m_httpd.cpp b/src/modules/m_httpd.cpp index 748f530ca..b453a2805 100644 --- a/src/modules/m_httpd.cpp +++ b/src/modules/m_httpd.cpp @@ -60,6 +60,7 @@ class HttpServerSocket : public BufferedSocket virtual void OnError(BufferedSocketError) { + ServerInstance->GlobalCulls.AddItem(this); } std::string Response(int response) @@ -326,6 +327,7 @@ class ModuleHttpServer : public Module ModuleHttpServer() { HttpModule = this; + ServerInstance->Modules->Attach(I_OnAcceptConnection, this); } void OnRequest(Request& request) @@ -339,7 +341,7 @@ class ModuleHttpServer : public Module ModResult OnAcceptConnection(int nfd, ListenSocket* from, irc::sockets::sockaddrs* client, irc::sockets::sockaddrs* server) { - if (from->bind_tag->getString("type") != "httpd"); + if (from->bind_tag->getString("type") != "httpd") return MOD_RES_PASSTHRU; int port; std::string incomingip;