summaryrefslogtreecommitdiff
path: root/src/coremods
diff options
context:
space:
mode:
authorAdam <Adam@anope.org>2016-10-01 22:03:53 -0400
committerAdam <Adam@anope.org>2017-07-12 18:57:35 -0400
commit35f7ac2a31ac31a2139939d78649a6faf4a185cc (patch)
tree67db665a5b6fcc49ea04065353654e80954732ad /src/coremods
parent0b0ef772755c265ef1fb5f9d9de3fdf9d50473e4 (diff)
cmd_kill: correct notices to show as a remote kill when a remote oper kills a local user
Diffstat (limited to 'src/coremods')
-rw-r--r--src/coremods/core_oper/cmd_kill.cpp13
1 files changed, 2 insertions, 11 deletions
diff --git a/src/coremods/core_oper/cmd_kill.cpp b/src/coremods/core_oper/cmd_kill.cpp
index c331d8ccd..059f2cbc1 100644
--- a/src/coremods/core_oper/cmd_kill.cpp
+++ b/src/coremods/core_oper/cmd_kill.cpp
@@ -90,10 +90,6 @@ CmdResult CommandKill::Handle (const std::vector<std::string>& parameters, User
killreason.assign(parameters[1], 0, ServerInstance->Config->Limits.MaxQuit);
}
- /*
- * Now we need to decide whether or not to send a local or remote snotice. Currently this checking is a little flawed.
- * No time to fix it right now, so left a note. -- w00t
- */
if (!IS_LOCAL(target))
{
// remote kill
@@ -103,17 +99,12 @@ CmdResult CommandKill::Handle (const std::vector<std::string>& parameters, User
}
else
{
- // local kill
- /*
- * XXX - this isn't entirely correct, servers A - B - C, oper on A, client on C. Oper kills client, A and B will get remote kill
- * snotices, C will get a local kill snotice. this isn't accurate, and needs fixing at some stage. -- w00t
- */
if ((!ServerInstance->Config->HideULineKills) || (!user->server->IsULine()))
{
if (IS_LOCAL(user))
- ServerInstance->SNO->WriteGlobalSno('k',"Local Kill by %s: %s (%s)", user->nick.c_str(), target->GetFullRealHost().c_str(), parameters[1].c_str());
+ ServerInstance->SNO->WriteGlobalSno('k', "Local kill by %s: %s (%s)", user->nick.c_str(), target->GetFullRealHost().c_str(), parameters[1].c_str());
else
- ServerInstance->SNO->WriteToSnoMask('k',"Local Kill by %s: %s (%s)", user->nick.c_str(), target->GetFullRealHost().c_str(), parameters[1].c_str());
+ ServerInstance->SNO->WriteToSnoMask('K', "Remote kill by %s: %s (%s)", user->nick.c_str(), target->GetFullRealHost().c_str(), parameters[1].c_str());
}
ServerInstance->Logs->Log("KILL", LOG_DEFAULT, "LOCAL KILL: %s :%s!%s!%s (%s)", target->nick.c_str(), ServerInstance->Config->ServerName.c_str(), user->dhost.c_str(), user->nick.c_str(), parameters[1].c_str());