From b0eca1dbccdbe5ac22b96375011a5cf51a487c47 Mon Sep 17 00:00:00 2001 From: Attila Molnar Date: Sun, 22 Jun 2014 13:17:57 +0200 Subject: [PATCH] core_ison Don't deduplicate nicks Deduplication makes us do pointless processing for every ISON and offers no benefit at all to proper clients that send a nick only once --- src/coremods/core_ison.cpp | 9 --------- 1 file changed, 9 deletions(-) diff --git a/src/coremods/core_ison.cpp b/src/coremods/core_ison.cpp index 1412db844..d127ed344 100644 --- a/src/coremods/core_ison.cpp +++ b/src/coremods/core_ison.cpp @@ -42,16 +42,12 @@ class CommandIson : public Command */ CmdResult CommandIson::Handle (const std::vector& parameters, User *user) { - std::map ison_already; User *u; std::string reply = "303 " + user->nick + " :"; for (unsigned int i = 0; i < parameters.size(); i++) { u = ServerInstance->FindNickOnly(parameters[i]); - if (ison_already.find(u) != ison_already.end()) - continue; - if ((u) && (u->registered == REG_ALL)) { reply.append(u->nick).append(" "); @@ -60,7 +56,6 @@ CmdResult CommandIson::Handle (const std::vector& parameters, User user->WriteServ(reply); reply = "303 " + user->nick + " :"; } - ison_already[u] = u; } else { @@ -74,9 +69,6 @@ CmdResult CommandIson::Handle (const std::vector& parameters, User while (list.GetToken(item)) { u = ServerInstance->FindNickOnly(item); - if (ison_already.find(u) != ison_already.end()) - continue; - if ((u) && (u->registered == REG_ALL)) { reply.append(u->nick).append(" "); @@ -85,7 +77,6 @@ CmdResult CommandIson::Handle (const std::vector& parameters, User user->WriteServ(reply); reply = "303 " + user->nick + " :"; } - ison_already[u] = u; } } } -- 2.39.5