diff options
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/m_auditorium.cpp | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/src/modules/m_auditorium.cpp b/src/modules/m_auditorium.cpp index 0ed4566e8..264418c5b 100644 --- a/src/modules/m_auditorium.cpp +++ b/src/modules/m_auditorium.cpp @@ -160,8 +160,7 @@ class ModuleAuditorium : public Module void OnUserQuit(User* user, const std::string &reason, const std::string &oper_message) { Command* parthandler = ServerInstance->Parser->GetHandler("PART"); - std::vector<std::string> to_leave; - const char* parameters[2]; + std::vector<std::string> to_leave, parameters; if (parthandler) { for (UCListIter f = user->chans.begin(); f != user->chans.end(); f++) @@ -172,9 +171,9 @@ 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(); + parameters[0] = *n; /* This triggers our OnUserPart, above, making the PART silent */ - parthandler->Handle(parameters, 1, user); + parthandler->Handle(parameters, user); } } } |