summaryrefslogtreecommitdiff
path: root/src/operserv.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/operserv.cpp')
-rw-r--r--src/operserv.cpp11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/operserv.cpp b/src/operserv.cpp
index c76b34375..6437fa2c9 100644
--- a/src/operserv.cpp
+++ b/src/operserv.cpp
@@ -324,9 +324,8 @@ XLine *XLineManager::GetEntry(unsigned index)
*/
void XLineManager::Clear()
{
- for (std::vector<XLine *>::iterator it = this->XLines.begin(), it_end = this->XLines.end(); it != it_end; ++it)
- delete *it;
- this->XLines.clear();
+ while (!this->XLines.empty())
+ this->DelXLine(this->XLines.front());
}
/** Add an entry to this XLine Manager
@@ -606,7 +605,7 @@ XLine *SNLineManager::Add(BotInfo *bi, User *u, const Anope::string &mask, time_
User *user = *it;
++it;
- if (!user->HasMode(UMODE_OPER) && Anope::Match(user->realname, x->Mask))
+ if (!user->HasMode(UMODE_OPER) && user->server != Me && Anope::Match(user->realname, x->Mask))
kill_user(Config->ServerName, user, rreason);
}
}
@@ -698,7 +697,7 @@ XLine *SQLineManager::Add(BotInfo *bi, User *u, const Anope::string &mask, time_
UserContainer *uc = *it;
++it;
- if (uc->user->HasMode(UMODE_OPER))
+ if (uc->user->HasMode(UMODE_OPER) || uc->user->server == Me)
continue;
c->Kick(NULL, uc->user, "%s", reason.c_str());
}
@@ -711,7 +710,7 @@ XLine *SQLineManager::Add(BotInfo *bi, User *u, const Anope::string &mask, time_
User *user = *it;
++it;
- if (!user->HasMode(UMODE_OPER) && Anope::Match(user->nick, x->Mask))
+ if (!user->HasMode(UMODE_OPER) && user->server != Me && Anope::Match(user->nick, x->Mask))
kill_user(Config->ServerName, user, rreason);
}
}