diff options
author | Adam <Adam@anope.org> | 2012-04-23 05:08:26 -0400 |
---|---|---|
committer | Adam <Adam@anope.org> | 2012-04-23 05:08:26 -0400 |
commit | 573e49a7ead331219eb6f0d3ca9cf83e793a5c9c (patch) | |
tree | e145e04fa3d041cf92ce46da4ac790b63231059c /modules/commands/os_sxline.cpp | |
parent | 63c639e108a00d7dbb0d7ac9891684fc83a3b207 (diff) |
Reworked live SQL support yet again
Diffstat (limited to 'modules/commands/os_sxline.cpp')
-rw-r--r-- | modules/commands/os_sxline.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/modules/commands/os_sxline.cpp b/modules/commands/os_sxline.cpp index d6c2ba094..c828b8d52 100644 --- a/modules/commands/os_sxline.cpp +++ b/modules/commands/os_sxline.cpp @@ -132,7 +132,7 @@ class CommandOSSXLineBase : public Command if (!Number) return; - XLine *x = this->xlm->GetEntry(Number - 1); + const XLine *x = this->xlm->GetEntry(Number - 1); if (!x) return; @@ -154,7 +154,7 @@ class CommandOSSXLineBase : public Command { for (unsigned i = 0, end = this->xlm()->GetCount(); i < end; ++i) { - XLine *x = this->xlm()->GetEntry(i); + const XLine *x = this->xlm()->GetEntry(i); if (mask.empty() || mask.equals_ci(x->Mask) || mask == x->UID || Anope::Match(x->Mask, mask, false, true)) { @@ -369,7 +369,7 @@ class CommandOSSNLine : public CommandOSSXLineBase { source.Reply(USERHOST_MASK_TOO_WIDE, mask.c_str()); Log(LOG_ADMIN, u, this) << "tried to " << source.command << " " << percent << "% of the network (" << affected << " users)"; - delete x; + x->destroy(); return; } @@ -377,7 +377,7 @@ class CommandOSSNLine : public CommandOSSXLineBase FOREACH_RESULT(I_OnAddXLine, OnAddXLine(u, x, this->xlm())); if (MOD_RESULT == EVENT_STOP) { - delete x; + x->destroy(); return; } @@ -576,7 +576,7 @@ class CommandOSSQLine : public CommandOSSXLineBase { source.Reply(USERHOST_MASK_TOO_WIDE, mask.c_str()); Log(LOG_ADMIN, u, this) << "tried to SQLine " << percent << "% of the network (" << affected << " users)"; - delete x; + x->destroy(); return; } @@ -584,7 +584,7 @@ class CommandOSSQLine : public CommandOSSXLineBase FOREACH_RESULT(I_OnAddXLine, OnAddXLine(u, x, this->xlm())); if (MOD_RESULT == EVENT_STOP) { - delete x; + x->destroy(); return; } |