From 6d03943426dcce76ba66567a9b18425a5ebb4c0c Mon Sep 17 00:00:00 2001 From: danieldg Date: Sat, 26 Sep 2009 14:13:13 +0000 Subject: Remove InspIRCd* parameters and fields git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11763 e03df62e-2008-0410-955e-edbf42e46eb7 --- src/commands/cmd_away.cpp | 4 ++-- src/commands/cmd_eline.cpp | 2 +- src/commands/cmd_gline.cpp | 2 +- src/commands/cmd_invite.cpp | 2 +- src/commands/cmd_join.cpp | 4 ++-- src/commands/cmd_kill.cpp | 2 +- src/commands/cmd_kline.cpp | 2 +- src/commands/cmd_nick.cpp | 6 +++--- src/commands/cmd_notice.cpp | 6 +++--- src/commands/cmd_privmsg.cpp | 6 +++--- src/commands/cmd_qline.cpp | 2 +- src/commands/cmd_rehash.cpp | 2 +- src/commands/cmd_user.cpp | 2 +- src/commands/cmd_whowas.cpp | 4 ++-- src/commands/cmd_zline.cpp | 2 +- 15 files changed, 24 insertions(+), 24 deletions(-) (limited to 'src/commands') diff --git a/src/commands/cmd_away.cpp b/src/commands/cmd_away.cpp index d93f74559..b0d432f29 100644 --- a/src/commands/cmd_away.cpp +++ b/src/commands/cmd_away.cpp @@ -52,7 +52,7 @@ CmdResult CommandAway::Handle (const std::vector& parameters, User if ((parameters.size()) && (!parameters[0].empty())) { - FIRST_MOD_RESULT(ServerInstance, OnSetAway, MOD_RESULT, (user, parameters[0])); + FIRST_MOD_RESULT(OnSetAway, MOD_RESULT, (user, parameters[0])); if (MOD_RESULT == MOD_RES_DENY && IS_LOCAL(user)) return CMD_FAILURE; @@ -64,7 +64,7 @@ CmdResult CommandAway::Handle (const std::vector& parameters, User } else { - FIRST_MOD_RESULT(ServerInstance, OnSetAway, MOD_RESULT, (user, "")); + FIRST_MOD_RESULT(OnSetAway, MOD_RESULT, (user, "")); if (MOD_RESULT == MOD_RES_DENY && IS_LOCAL(user)) return CMD_FAILURE; diff --git a/src/commands/cmd_eline.cpp b/src/commands/cmd_eline.cpp index 7845fa2f1..6ea3df7c5 100644 --- a/src/commands/cmd_eline.cpp +++ b/src/commands/cmd_eline.cpp @@ -87,7 +87,7 @@ CmdResult CommandEline::Handle (const std::vector& parameters, User long duration = ServerInstance->Duration(parameters[1].c_str()); - ELine* el = new ELine(ServerInstance, ServerInstance->Time(), duration, user->nick.c_str(), parameters[2].c_str(), ih.first.c_str(), ih.second.c_str()); + ELine* el = new ELine(ServerInstance->Time(), duration, user->nick.c_str(), parameters[2].c_str(), ih.first.c_str(), ih.second.c_str()); if (ServerInstance->XLines->AddLine(el, user)) { if (!duration) diff --git a/src/commands/cmd_gline.cpp b/src/commands/cmd_gline.cpp index ad3067428..ea2850f6f 100644 --- a/src/commands/cmd_gline.cpp +++ b/src/commands/cmd_gline.cpp @@ -70,7 +70,7 @@ CmdResult CommandGline::Handle (const std::vector& parameters, User } long duration = ServerInstance->Duration(parameters[1].c_str()); - GLine* gl = new GLine(ServerInstance, ServerInstance->Time(), duration, user->nick.c_str(), parameters[2].c_str(), ih.first.c_str(), ih.second.c_str()); + GLine* gl = new GLine(ServerInstance->Time(), duration, user->nick.c_str(), parameters[2].c_str(), ih.first.c_str(), ih.second.c_str()); if (ServerInstance->XLines->AddLine(gl, user)) { if (!duration) diff --git a/src/commands/cmd_invite.cpp b/src/commands/cmd_invite.cpp index 89437e252..9da6096a4 100644 --- a/src/commands/cmd_invite.cpp +++ b/src/commands/cmd_invite.cpp @@ -70,7 +70,7 @@ CmdResult CommandInvite::Handle (const std::vector& parameters, Use return CMD_FAILURE; } - FIRST_MOD_RESULT(ServerInstance, OnUserPreInvite, MOD_RESULT, (user,u,c,timeout)); + FIRST_MOD_RESULT(OnUserPreInvite, MOD_RESULT, (user,u,c,timeout)); if (MOD_RESULT == MOD_RES_DENY) { diff --git a/src/commands/cmd_join.cpp b/src/commands/cmd_join.cpp index 73cae4746..806823f76 100644 --- a/src/commands/cmd_join.cpp +++ b/src/commands/cmd_join.cpp @@ -55,7 +55,7 @@ CmdResult CommandJoin::Handle (const std::vector& parameters, User if (ServerInstance->IsChannel(parameters[0].c_str(), ServerInstance->Config->Limits.ChanMax)) { - Channel::JoinUser(ServerInstance, user, parameters[0].c_str(), false, parameters[1].c_str(), false); + Channel::JoinUser(user, parameters[0].c_str(), false, parameters[1].c_str(), false); return CMD_SUCCESS; } } @@ -66,7 +66,7 @@ CmdResult CommandJoin::Handle (const std::vector& parameters, User if (ServerInstance->IsChannel(parameters[0].c_str(), ServerInstance->Config->Limits.ChanMax)) { - Channel::JoinUser(ServerInstance, user, parameters[0].c_str(), false, "", false); + Channel::JoinUser(user, parameters[0].c_str(), false, "", false); return CMD_SUCCESS; } } diff --git a/src/commands/cmd_kill.cpp b/src/commands/cmd_kill.cpp index 1001d4c8a..88db2764d 100644 --- a/src/commands/cmd_kill.cpp +++ b/src/commands/cmd_kill.cpp @@ -60,7 +60,7 @@ CmdResult CommandKill::Handle (const std::vector& parameters, User * Moved this event inside the IS_LOCAL check also, we don't want half the network killing a user * and the other half not. This would be a bad thing. ;p -- w00t */ - FIRST_MOD_RESULT(ServerInstance, OnKill, MOD_RESULT, (user, u, parameters[1])); + FIRST_MOD_RESULT(OnKill, MOD_RESULT, (user, u, parameters[1])); if (MOD_RESULT == MOD_RES_DENY) return CMD_FAILURE; diff --git a/src/commands/cmd_kline.cpp b/src/commands/cmd_kline.cpp index 3ec2461b4..9184a3505 100644 --- a/src/commands/cmd_kline.cpp +++ b/src/commands/cmd_kline.cpp @@ -70,7 +70,7 @@ CmdResult CommandKline::Handle (const std::vector& parameters, User } long duration = ServerInstance->Duration(parameters[1].c_str()); - KLine* kl = new KLine(ServerInstance, ServerInstance->Time(), duration, user->nick.c_str(), parameters[2].c_str(), ih.first.c_str(), ih.second.c_str()); + KLine* kl = new KLine(ServerInstance->Time(), duration, user->nick.c_str(), parameters[2].c_str(), ih.first.c_str(), ih.second.c_str()); if (ServerInstance->XLines->AddLine(kl,user)) { if (!duration) diff --git a/src/commands/cmd_nick.cpp b/src/commands/cmd_nick.cpp index 99b8348ab..bdaff8723 100644 --- a/src/commands/cmd_nick.cpp +++ b/src/commands/cmd_nick.cpp @@ -84,7 +84,7 @@ CmdResult CommandNick::Handle (const std::vector& parameters, User */ oldnick.assign(user->nick, 0, IS_LOCAL(user) ? ServerInstance->Config->Limits.NickMax : MAXBUF); ModResult MOD_RESULT; - FIRST_MOD_RESULT(ServerInstance, OnUserPreNick, MOD_RESULT, (user,parameters[0])); + FIRST_MOD_RESULT(OnUserPreNick, MOD_RESULT, (user,parameters[0])); if (MOD_RESULT == MOD_RES_DENY) return CMD_FAILURE; if (user->registered == REG_ALL) @@ -165,7 +165,7 @@ CmdResult CommandNick::Handle (const std::vector& parameters, User ModResult MOD_RESULT; - FIRST_MOD_RESULT(ServerInstance, OnUserPreNick, MOD_RESULT, (user, parameters[0])); + FIRST_MOD_RESULT(OnUserPreNick, MOD_RESULT, (user, parameters[0])); if (MOD_RESULT == MOD_RES_DENY) // if a module returns true, the nick change is silently forbidden. return CMD_FAILURE; @@ -191,7 +191,7 @@ CmdResult CommandNick::Handle (const std::vector& parameters, User if (user->registered == REG_NICKUSER) { /* user is registered now, bit 0 = USER command, bit 1 = sent a NICK command */ - FIRST_MOD_RESULT(ServerInstance, OnUserRegister, MOD_RESULT, (user)); + FIRST_MOD_RESULT(OnUserRegister, MOD_RESULT, (user)); if (MOD_RESULT == MOD_RES_DENY) return CMD_FAILURE; diff --git a/src/commands/cmd_notice.cpp b/src/commands/cmd_notice.cpp index ced17072f..a14473643 100644 --- a/src/commands/cmd_notice.cpp +++ b/src/commands/cmd_notice.cpp @@ -51,7 +51,7 @@ CmdResult CommandNotice::Handle (const std::vector& parameters, Use ModResult MOD_RESULT; std::string temp = parameters[1]; - FIRST_MOD_RESULT(ServerInstance, OnUserPreNotice, MOD_RESULT, (user, (void*)parameters[0].c_str(), TYPE_SERVER, temp, 0, exempt_list)); + FIRST_MOD_RESULT(OnUserPreNotice, MOD_RESULT, (user, (void*)parameters[0].c_str(), TYPE_SERVER, temp, 0, exempt_list)); if (MOD_RESULT == MOD_RES_DENY) return CMD_FAILURE; const char* text = temp.c_str(); @@ -97,7 +97,7 @@ CmdResult CommandNotice::Handle (const std::vector& parameters, Use ModResult MOD_RESULT; std::string temp = parameters[1]; - FIRST_MOD_RESULT(ServerInstance, OnUserPreNotice, MOD_RESULT, (user,chan,TYPE_CHANNEL,temp,status, exempt_list)); + FIRST_MOD_RESULT(OnUserPreNotice, MOD_RESULT, (user,chan,TYPE_CHANNEL,temp,status, exempt_list)); if (MOD_RESULT == MOD_RES_DENY) return CMD_FAILURE; @@ -173,7 +173,7 @@ CmdResult CommandNotice::Handle (const std::vector& parameters, Use ModResult MOD_RESULT; std::string temp = parameters[1]; - FIRST_MOD_RESULT(ServerInstance, OnUserPreNotice, MOD_RESULT, (user,dest,TYPE_USER,temp,0,exempt_list)); + FIRST_MOD_RESULT(OnUserPreNotice, MOD_RESULT, (user,dest,TYPE_USER,temp,0,exempt_list)); if (MOD_RESULT == MOD_RES_DENY) { return CMD_FAILURE; } diff --git a/src/commands/cmd_privmsg.cpp b/src/commands/cmd_privmsg.cpp index 781ad8bac..0eacfd0bc 100644 --- a/src/commands/cmd_privmsg.cpp +++ b/src/commands/cmd_privmsg.cpp @@ -51,7 +51,7 @@ CmdResult CommandPrivmsg::Handle (const std::vector& parameters, Us ModResult MOD_RESULT; std::string temp = parameters[1]; - FIRST_MOD_RESULT(ServerInstance, OnUserPreMessage, MOD_RESULT, (user, (void*)parameters[0].c_str(), TYPE_SERVER, temp, 0, except_list)); + FIRST_MOD_RESULT(OnUserPreMessage, MOD_RESULT, (user, (void*)parameters[0].c_str(), TYPE_SERVER, temp, 0, except_list)); if (MOD_RESULT == MOD_RES_DENY) return CMD_FAILURE; @@ -108,7 +108,7 @@ CmdResult CommandPrivmsg::Handle (const std::vector& parameters, Us ModResult MOD_RESULT; std::string temp = parameters[1]; - FIRST_MOD_RESULT(ServerInstance, OnUserPreMessage, MOD_RESULT, (user,chan,TYPE_CHANNEL,temp,status,except_list)); + FIRST_MOD_RESULT(OnUserPreMessage, MOD_RESULT, (user,chan,TYPE_CHANNEL,temp,status,except_list)); if (MOD_RESULT == MOD_RES_DENY) return CMD_FAILURE; @@ -192,7 +192,7 @@ CmdResult CommandPrivmsg::Handle (const std::vector& parameters, Us ModResult MOD_RESULT; std::string temp = parameters[1]; - FIRST_MOD_RESULT(ServerInstance, OnUserPreMessage, MOD_RESULT, (user, dest, TYPE_USER, temp, 0, except_list)); + FIRST_MOD_RESULT(OnUserPreMessage, MOD_RESULT, (user, dest, TYPE_USER, temp, 0, except_list)); if (MOD_RESULT == MOD_RES_DENY) return CMD_FAILURE; diff --git a/src/commands/cmd_qline.cpp b/src/commands/cmd_qline.cpp index ffe8c5ee6..762fd53c4 100644 --- a/src/commands/cmd_qline.cpp +++ b/src/commands/cmd_qline.cpp @@ -45,7 +45,7 @@ CmdResult CommandQline::Handle (const std::vector& parameters, User } long duration = ServerInstance->Duration(parameters[1].c_str()); - QLine* ql = new QLine(ServerInstance, ServerInstance->Time(), duration, user->nick.c_str(), parameters[2].c_str(), parameters[0].c_str()); + QLine* ql = new QLine(ServerInstance->Time(), duration, user->nick.c_str(), parameters[2].c_str(), parameters[0].c_str()); if (ServerInstance->XLines->AddLine(ql,user)) { if (!duration) diff --git a/src/commands/cmd_rehash.cpp b/src/commands/cmd_rehash.cpp index b2a9fbde4..5d5caa32a 100644 --- a/src/commands/cmd_rehash.cpp +++ b/src/commands/cmd_rehash.cpp @@ -85,7 +85,7 @@ CmdResult CommandRehash::Handle (const std::vector& parameters, Use FOREACH_MOD(I_OnGarbageCollect, OnGarbageCollect()); - ServerInstance->ConfigThread = new ConfigReaderThread(ServerInstance, user->uuid); + ServerInstance->ConfigThread = new ConfigReaderThread(user->uuid); ServerInstance->Threads->Start(ServerInstance->ConfigThread); return CMD_SUCCESS; diff --git a/src/commands/cmd_user.cpp b/src/commands/cmd_user.cpp index e2f81f33c..e396e0c84 100644 --- a/src/commands/cmd_user.cpp +++ b/src/commands/cmd_user.cpp @@ -71,7 +71,7 @@ CmdResult CommandUser::Handle (const std::vector& parameters, User ModResult MOD_RESULT; /* user is registered now, bit 0 = USER command, bit 1 = sent a NICK command */ - FIRST_MOD_RESULT(ServerInstance, OnUserRegister, MOD_RESULT, (user)); + FIRST_MOD_RESULT(OnUserRegister, MOD_RESULT, (user)); if (MOD_RESULT == MOD_RES_DENY) return CMD_FAILURE; diff --git a/src/commands/cmd_whowas.cpp b/src/commands/cmd_whowas.cpp index 78a7e7544..4a9ac9499 100644 --- a/src/commands/cmd_whowas.cpp +++ b/src/commands/cmd_whowas.cpp @@ -20,7 +20,7 @@ CommandWhowas::CommandWhowas( Module* parent) : Command(parent, "WHOWAS", 1) { syntax = "{,}"; Penalty = 2; - timer = new WhoWasMaintainTimer(ServerInstance, 3600); + timer = new WhoWasMaintainTimer(3600); ServerInstance->Timers->AddTimer(timer); } @@ -309,7 +309,7 @@ class ModuleWhoWas : public Module { CommandWhowas cmd; public: - ModuleWhoWas(InspIRCd *Me) : Module(Me), cmd(this) + ModuleWhoWas() : cmd(this) { ServerInstance->AddCommand(&cmd); } diff --git a/src/commands/cmd_zline.cpp b/src/commands/cmd_zline.cpp index e2cca7649..d37300974 100644 --- a/src/commands/cmd_zline.cpp +++ b/src/commands/cmd_zline.cpp @@ -66,7 +66,7 @@ CmdResult CommandZline::Handle (const std::vector& parameters, User long duration = ServerInstance->Duration(parameters[1].c_str()); - ZLine* zl = new ZLine(ServerInstance, ServerInstance->Time(), duration, user->nick.c_str(), parameters[2].c_str(), ipaddr); + ZLine* zl = new ZLine(ServerInstance->Time(), duration, user->nick.c_str(), parameters[2].c_str(), ipaddr); if (ServerInstance->XLines->AddLine(zl,user)) { if (!duration) -- cgit v1.2.3