summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-02-23 19:46:43 +0000
committerbrain <brain@e03df62e-2008-0410-955e-edbf42e46eb7>2006-02-23 19:46:43 +0000
commitaca9acf422c76fefa4223f3add27e62e860f2f62 (patch)
tree726f275e500768e26c3e8639bf2fb3bf6c47fa0d
parent7907a1f1cc78ca532547c824cd221060b57f4fff (diff)
Fixed to work
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@3302 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r--include/modules.h1
-rw-r--r--src/inspircd.cpp1
-rw-r--r--src/modules.cpp1
-rw-r--r--src/modules/m_safelist.cpp10
4 files changed, 6 insertions, 7 deletions
diff --git a/include/modules.h b/include/modules.h
index 56bf2d18f..8eae4f6a3 100644
--- a/include/modules.h
+++ b/include/modules.h
@@ -72,6 +72,7 @@ enum TargetTypeFlags {
#include <deque>
#include <sstream>
#include <typeinfo>
+#include "timer.h"
class Server;
class ServerConfig;
diff --git a/src/inspircd.cpp b/src/inspircd.cpp
index 6e8040d87..acd8a4d85 100644
--- a/src/inspircd.cpp
+++ b/src/inspircd.cpp
@@ -57,7 +57,6 @@ using namespace std;
#include "socket.h"
#include "typedefs.h"
#include "command_parse.h"
-#include "timer.h"
InspIRCd* ServerInstance;
diff --git a/src/modules.cpp b/src/modules.cpp
index 7640f0edc..c562161e0 100644
--- a/src/modules.cpp
+++ b/src/modules.cpp
@@ -50,7 +50,6 @@ using namespace std;
#include "typedefs.h"
#include "modules.h"
#include "command_parse.h"
-#include "timer.h"
extern ServerConfig *Config;
extern InspIRCd* ServerInstance;
diff --git a/src/modules/m_safelist.cpp b/src/modules/m_safelist.cpp
index 52e5e36a0..06c7ef348 100644
--- a/src/modules/m_safelist.cpp
+++ b/src/modules/m_safelist.cpp
@@ -45,14 +45,14 @@ class ListTimer : public InspTimer
private:
Server* Srv;
public:
- ListTimer(long interval, Server* Me) : InspTimer(interval), Server(Me)
+ ListTimer(long interval, Server* Me) : InspTimer(interval), Srv(Me)
{
}
- Tick(time_t TIME)
+ virtual void Tick(time_t TIME)
{
log(DEBUG,"*** Timer tick!");
- MyTimer = new ListTimer(1);
+ ListTimer* MyTimer = new ListTimer(1,Srv);
Srv->AddTimer(MyTimer);
}
};
@@ -68,8 +68,8 @@ class ModuleSafeList : public Module
{
Srv = Me;
- MyTimer = new ListTimer(1);
- Srv->AddTimer(MyTimer,Me);
+ MyTimer = new ListTimer(1,Srv);
+ Srv->AddTimer(MyTimer);
}
virtual ~ModuleSafeList()