X-Git-Url: https://git.netwichtig.de/gitweb/?a=blobdiff_plain;f=src%2Fmodules%2Fm_httpd_config.cpp;h=cfdaa4290c3bd0e525290c097db4a243b07e20dd;hb=e9e75e50bc25e67af22dd88b39b12217a553d5cb;hp=0df1c12fb6355967c31b5736de35cae67db90a04;hpb=804c02174fd61143f6da5580dd0e28bd9f1bb8a8;p=user%2Fhenk%2Fcode%2Finspircd.git diff --git a/src/modules/m_httpd_config.cpp b/src/modules/m_httpd_config.cpp index 0df1c12fb..cfdaa4290 100644 --- a/src/modules/m_httpd_config.cpp +++ b/src/modules/m_httpd_config.cpp @@ -19,7 +19,7 @@ #include "inspircd.h" -#include "httpd.h" +#include "modules/httpd.h" #include "protocol.h" /* $ModDesc: Allows for the server configuration to be viewed over HTTP via m_httpd.so */ @@ -27,9 +27,10 @@ class ModuleHttpConfig : public Module { public: - ModuleHttpConfig() { + void init() + { Implementation eventlist[] = { I_OnEvent }; - ServerInstance->Modules->Attach(eventlist, this, 1); + ServerInstance->Modules->Attach(eventlist, this, sizeof(eventlist)/sizeof(Implementation)); } std::string Sanitize(const std::string &str) @@ -72,7 +73,7 @@ class ModuleHttpConfig : public Module if (event.id == "httpd_url") { - ServerInstance->Logs->Log("m_http_stats", DEBUG,"Handling httpd event"); + ServerInstance->Logs->Log("m_http_stats", LOG_DEBUG,"Handling httpd event"); HTTPRequest* http = (HTTPRequest*)&event; if ((http->GetURI() == "/config") || (http->GetURI() == "/config/")) @@ -101,10 +102,6 @@ class ModuleHttpConfig : public Module } } - virtual ~ModuleHttpConfig() - { - } - virtual Version GetVersion() { return Version("Allows for the server configuration to be viewed over HTTP via m_httpd.so", VF_VENDOR);