summaryrefslogtreecommitdiff
path: root/src/modules/m_knock.cpp
diff options
context:
space:
mode:
authorw00t <w00t@e03df62e-2008-0410-955e-edbf42e46eb7>2007-08-28 19:27:19 +0000
committerw00t <w00t@e03df62e-2008-0410-955e-edbf42e46eb7>2007-08-28 19:27:19 +0000
commit0549fb41568be278319326ae55be69018e2e5aa8 (patch)
tree063b63d39d8876017a9d04b3b49782151112e6ba /src/modules/m_knock.cpp
parent2ccbc50453f3e70397299b83ba28d0289535b947 (diff)
DELETE() -> delete
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@7973 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules/m_knock.cpp')
-rw-r--r--src/modules/m_knock.cpp5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/modules/m_knock.cpp b/src/modules/m_knock.cpp
index 3f9608935..5ed69273e 100644
--- a/src/modules/m_knock.cpp
+++ b/src/modules/m_knock.cpp
@@ -100,10 +100,11 @@ class ModuleKnock : public Module
public:
ModuleKnock(InspIRCd* Me) : Module(Me)
{
-
kn = new Knock(ServerInstance);
+
if (!ServerInstance->AddMode(kn, 'K'))
throw ModuleException("Could not add new modes!");
+
mycommand = new cmd_knock(ServerInstance);
ServerInstance->AddCommand(mycommand);
}
@@ -115,7 +116,7 @@ class ModuleKnock : public Module
virtual ~ModuleKnock()
{
ServerInstance->Modes->DelMode(kn);
- DELETE(kn);
+ delete kn;
}
virtual Version GetVersion()