]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_auditorium.cpp
Fix warning
[user/henk/code/inspircd.git] / src / modules / m_auditorium.cpp
index 0ed4566e84929b6ce7416ca266a144b02d41d138..75f953f437f19dd5553701e88c00524320dba740 100644 (file)
@@ -161,7 +161,6 @@ class ModuleAuditorium : public Module
        {
                Command* parthandler = ServerInstance->Parser->GetHandler("PART");
                std::vector<std::string> to_leave;
-               const char* parameters[2];
                if (parthandler)
                {
                        for (UCListIter f = user->chans.begin(); f != user->chans.end(); f++)
@@ -172,9 +171,10 @@ class ModuleAuditorium : 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();
+                               std::vector<std::string> parameters;
+                               parameters.push_back(*n);
                                /* This triggers our OnUserPart, above, making the PART silent */
-                               parthandler->Handle(parameters, 1, user);
+                               parthandler->Handle(parameters, user);
                        }
                }
        }