summaryrefslogtreecommitdiff
path: root/src/modules/m_invisible.cpp
diff options
context:
space:
mode:
authorpeavey <peavey@e03df62e-2008-0410-955e-edbf42e46eb7>2008-05-05 00:18:01 +0000
committerpeavey <peavey@e03df62e-2008-0410-955e-edbf42e46eb7>2008-05-05 00:18:01 +0000
commit5f6955a43ee286925d9f79affcb2fdd5e9306fe6 (patch)
tree31a239d90de618836cae746040e8f229f209a995 /src/modules/m_invisible.cpp
parent8e89fe75f9467969bce1dc6930befc6ef273edf6 (diff)
Convert convert convert
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@9624 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules/m_invisible.cpp')
-rw-r--r--src/modules/m_invisible.cpp12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/modules/m_invisible.cpp b/src/modules/m_invisible.cpp
index b90394164..de573dfde 100644
--- a/src/modules/m_invisible.cpp
+++ b/src/modules/m_invisible.cpp
@@ -140,8 +140,10 @@ class InvisibleDeOper : public ModeWatcher
/* Users who are opers and have +Q get their +Q removed when they deoper */
if ((!adding) && (dest->IsModeSet('Q')))
{
- const char* newmodes[] = { dest->nick, "-Q" };
- ServerInstance->Modes->Process(newmodes, 2, source, true);
+ std::vector<std::string> newmodes;
+ newmodes[0] = dest->nick;
+ newmodes[1] = "-Q";
+ ServerInstance->Modes->Process(newmodes, source, true);
}
return true;
}
@@ -221,7 +223,7 @@ class ModuleInvisible : public Module
{
Command* parthandler = ServerInstance->Parser->GetHandler("PART");
std::vector<std::string> to_leave;
- const char* parameters[2];
+ std::vector<std::string> parameters;
if (parthandler)
{
for (UCListIter f = user->chans.begin(); f != user->chans.end(); f++)
@@ -229,9 +231,9 @@ class ModuleInvisible : public Module
/* We cant do this neatly in one loop, as we are modifying the map we are iterating */
for (std::vector<std::string>::iterator n = to_leave.begin(); n != to_leave.end(); n++)
{
- parameters[0] = n->c_str();
+ parameters[0] = *n;
/* This triggers our OnUserPart, above, making the PART silent */
- parthandler->Handle(parameters, 1, user);
+ parthandler->Handle(parameters, user);
}
}
}