summaryrefslogtreecommitdiff
path: root/src/modules/m_safelist.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/m_safelist.cpp')
-rw-r--r--src/modules/m_safelist.cpp21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/modules/m_safelist.cpp b/src/modules/m_safelist.cpp
index 641fd7559..52e5e36a0 100644
--- a/src/modules/m_safelist.cpp
+++ b/src/modules/m_safelist.cpp
@@ -40,15 +40,36 @@ class ListData
typedef std::vector<userrec *> UserList;
+class ListTimer : public InspTimer
+{
+ private:
+ Server* Srv;
+ public:
+ ListTimer(long interval, Server* Me) : InspTimer(interval), Server(Me)
+ {
+ }
+
+ Tick(time_t TIME)
+ {
+ log(DEBUG,"*** Timer tick!");
+ MyTimer = new ListTimer(1);
+ Srv->AddTimer(MyTimer);
+ }
+};
+
class ModuleSafeList : public Module
{
private:
Server *Srv;
+ ListTimer* MyTimer;
UserList listusers; /* vector of people doing a /list */
public:
ModuleSafeList(Server* Me) : Module::Module(Me)
{
Srv = Me;
+
+ MyTimer = new ListTimer(1);
+ Srv->AddTimer(MyTimer,Me);
}
virtual ~ModuleSafeList()