summaryrefslogtreecommitdiff
path: root/src/modules/m_cgiirc.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/m_cgiirc.cpp')
-rw-r--r--src/modules/m_cgiirc.cpp10
1 files changed, 2 insertions, 8 deletions
diff --git a/src/modules/m_cgiirc.cpp b/src/modules/m_cgiirc.cpp
index 6df039dce..a5f0bca3e 100644
--- a/src/modules/m_cgiirc.cpp
+++ b/src/modules/m_cgiirc.cpp
@@ -261,10 +261,7 @@ public:
{
bool cached;
CGIResolver* r = new CGIResolver(this, ServerInstance, NotifyOpers, user->password, false, user, user->GetFd(), "PASS", cached);
- if (!cached)
- ServerInstance->AddResolver(r);
- else
- delete r;
+ ServerInstance->AddResolver(r, cached);
}
catch (ModuleException& e)
{
@@ -321,10 +318,7 @@ public:
ServerInstance->Log(DEBUG,"MAKE RESOLVER: %s %d %s",newip, user->GetFd(), "IDENT");
bool cached;
CGIResolver* r = new CGIResolver(this, ServerInstance, NotifyOpers, newip, false, user, user->GetFd(), "IDENT", cached);
- if (!cached)
- ServerInstance->AddResolver(r);
- else
- delete r;
+ ServerInstance->AddResolver(r, cached);
}
catch (ModuleException& e)
{