diff options
author | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-11-12 15:44:54 +0000 |
---|---|---|
committer | brain <brain@e03df62e-2008-0410-955e-edbf42e46eb7> | 2006-11-12 15:44:54 +0000 |
commit | ddbd88314157ac990382deb4eb5d34e38097c96a (patch) | |
tree | 3a65cf0461dae360df569577dab1445142e085b9 | |
parent | c5d1e3bcb7afc68ba20f85c4e530b29a56bee57b (diff) |
Needs testing: SAMODE doesnt send the actual SAMODE text any more, instead it sends a server-origin MODE
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@5705 e03df62e-2008-0410-955e-edbf42e46eb7
-rw-r--r-- | src/modules/m_samode.cpp | 16 |
1 files changed, 15 insertions, 1 deletions
diff --git a/src/modules/m_samode.cpp b/src/modules/m_samode.cpp index 5fa694ddd..34278101e 100644 --- a/src/modules/m_samode.cpp +++ b/src/modules/m_samode.cpp @@ -62,7 +62,21 @@ class cmd_samode : public command_t if (ServerInstance->Modes->GetLastParse().length()) { ServerInstance->WriteOpers(std::string(user->nick)+" used SAMODE: "+ServerInstance->Modes->GetLastParse()); - return CMD_SUCCESS; + + std::deque<std::string> n; + irc::spacesepstream spaced(ServerInstance->Modes->GetLastParse()); + std::string one = "*"; + while ((one = spaced.GetToken()) != "") + n.push_back(one); + + Event rmode((char *)&n, NULL, "send_mode_explicit"); + rmode.Send(ServerInstance); + + /* XXX: Yes, this is right. We dont want to propogate the + * actual SAMODE command, just the MODE command generated + * by the send_mode_explicit + */ + return CMD_FAILURE; } return CMD_FAILURE; |