summaryrefslogtreecommitdiff
path: root/src/modules/m_httpd.cpp
diff options
context:
space:
mode:
authordanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-09-26 14:13:13 +0000
committerdanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-09-26 14:13:13 +0000
commit6d03943426dcce76ba66567a9b18425a5ebb4c0c (patch)
treebedffa6d2a65a9ef556405224a6d7a181c8a1ba5 /src/modules/m_httpd.cpp
parent810c662c9b55908101ca085293c52c3239ef22d1 (diff)
Remove InspIRCd* parameters and fields
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11763 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules/m_httpd.cpp')
-rw-r--r--src/modules/m_httpd.cpp15
1 files changed, 7 insertions, 8 deletions
diff --git a/src/modules/m_httpd.cpp b/src/modules/m_httpd.cpp
index 929697c5f..e9d05d3e5 100644
--- a/src/modules/m_httpd.cpp
+++ b/src/modules/m_httpd.cpp
@@ -315,11 +315,11 @@ class HttpServerSocket : public BufferedSocket
claimed = false;
HTTPRequest httpr(request_type,uri,&headers,this,ip,postdata);
Event acl((char*)&httpr, (Module*)HttpModule, "httpd_acl");
- acl.Send(ServerInstance);
+ acl.Send();
if (!claimed)
{
Event e((char*)&httpr, (Module*)HttpModule, "httpd_url");
- e.Send(ServerInstance);
+ e.Send();
if (!claimed)
{
SendHTTPError(404);
@@ -342,7 +342,7 @@ class HttpListener : public ListenSocketBase
FileReader* index;
public:
- HttpListener(InspIRCd* Instance, FileReader *idx, int port, const std::string &addr) : ListenSocketBase(Instance, port, addr)
+ HttpListener(FileReader *idx, int port, const std::string &addr) : ListenSocketBase(port, addr)
{
this->index = idx;
}
@@ -370,7 +370,7 @@ class ModuleHttpServer : public Module
std::string indexfile;
FileReader* index;
HttpListener *http;
- ConfigReader c(ServerInstance);
+ ConfigReader c;
httpsocks.clear(); // XXX this will BREAK if this module is made rehashable
httplisteners.clear();
@@ -381,16 +381,15 @@ class ModuleHttpServer : public Module
bindip = c.ReadValue("http", "ip", i);
port = c.ReadInteger("http", "port", i, true);
indexfile = c.ReadValue("http", "index", i);
- index = new FileReader(ServerInstance, indexfile);
+ index = new FileReader(indexfile);
if (!index->Exists())
throw ModuleException("Can't read index file: "+indexfile);
- http = new HttpListener(ServerInstance, index, port, (char *)bindip.c_str()); // XXX this cast SUCKS.
+ http = new HttpListener(index, port, (char *)bindip.c_str()); // XXX this cast SUCKS.
httplisteners.push_back(http);
}
}
- ModuleHttpServer(InspIRCd* Me) : Module(Me)
- {
+ ModuleHttpServer() {
ReadConfig();
HttpModule = this;
Implementation eventlist[] = { I_OnRequest };