aboutsummaryrefslogtreecommitdiffstats
path: root/src/modules
diff options
context:
space:
mode:
authorGravatar brain2007-10-13 21:34:45 +0000
committerGravatar brain2007-10-13 21:34:45 +0000
commit7bb52e812e5360f7c17d50f3462da56f150bc78b (patch)
tree33476db7e02f377391c4eab94a36c78646be7344 /src/modules
parentExtra sanity checks to openssl module events to check for out of range file d... (diff)
This fixes a deletion error here, we were using new[] and not using delete[], but delete instead.
git-svn-id: http://svn.inspircd.org/repository/branches/1_1_stable@8158 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/m_conn_waitpong.cpp18
1 files changed, 9 insertions, 9 deletions
diff --git a/src/modules/m_conn_waitpong.cpp b/src/modules/m_conn_waitpong.cpp
index 0dd27ddbd..acd4e27ff 100644
--- a/src/modules/m_conn_waitpong.cpp
+++ b/src/modules/m_conn_waitpong.cpp
@@ -76,16 +76,16 @@ class ModuleWaitPong : public Module
virtual int OnPreCommand(const std::string &command, const char** parameters, int pcnt, userrec* user, bool validated, const std::string &original_line)
{
- if(command == "PONG")
+ if (command == "PONG")
{
char* pingrpl;
user->GetExt(extenstr, pingrpl);
- if(pingrpl)
+ if (pingrpl)
{
- if(strcmp(pingrpl, parameters[0]) == 0)
+ if (strcmp(pingrpl, parameters[0]) == 0)
{
- DELETE(pingrpl);
+ delete[] pingrpl;
user->Shrink(extenstr);
return 1;
}
@@ -111,24 +111,24 @@ class ModuleWaitPong : public Module
char* pingrpl;
user->GetExt(extenstr, pingrpl);
- if(pingrpl)
+ if (pingrpl)
{
- DELETE(pingrpl);
+ delete[] pingrpl;
user->Shrink(extenstr);
}
}
virtual void OnCleanup(int target_type, void* item)
{
- if(target_type == TYPE_USER)
+ if (target_type == TYPE_USER)
{
userrec* user = (userrec*)item;
char* pingrpl;
user->GetExt(extenstr, pingrpl);
- if(pingrpl)
+ if (pingrpl)
{
- DELETE(pingrpl);
+ delete[] pingrpl;
user->Shrink(extenstr);
}
}