]> git.netwichtig.de Git - user/henk/code/inspircd.git/commitdiff
Change type of snomask parameter to char in ProtocolInterface::SendSNONotice()
authorAttila Molnar <attilamolnar@hush.com>
Sat, 4 Jan 2014 18:43:04 +0000 (19:43 +0100)
committerAttila Molnar <attilamolnar@hush.com>
Sat, 4 Jan 2014 18:43:04 +0000 (19:43 +0100)
include/protocol.h
src/modules/m_spanningtree/main.cpp
src/modules/m_spanningtree/protocolinterface.cpp
src/modules/m_spanningtree/protocolinterface.h
src/snomasks.cpp

index b077a4f4766190f04c74d890eb891fe650b924c2..4afb0bf59165cb86890330bdaa1edf62db543c8c 100644 (file)
@@ -104,7 +104,7 @@ class CoreExport ProtocolInterface
         * @param snomask The snomask required for the message to be sent.
         * @param text The message to send.
         */
-       virtual void SendSNONotice(const std::string &snomask, const std::string &text) { }
+       virtual void SendSNONotice(char snomask, const std::string& text) { }
 
        /** Send raw data to a remote client.
         * @param target The user to push data to.
index 39ff222c52a39eacaf2e7a7e87e079a8ec6e05c5..8d8a51ede496e1f43f40146884669499ad17ec47 100644 (file)
@@ -631,7 +631,7 @@ void ModuleSpanningTree::ReadConfig(ConfigStatus& status)
                msg.append(e.GetReason());
                ServerInstance->SNO->WriteToSnoMask('l', msg);
                if (status.srcuser && !IS_LOCAL(status.srcuser))
-                       ServerInstance->PI->SendSNONotice("L", msg);
+                       ServerInstance->PI->SendSNONotice('L', msg);
        }
 }
 
index a6c826c7bf0c763cdc4006206099c01658e789d6..7a2b033d93c03875d709ff2cd0f0410c93b1506c 100644 (file)
@@ -103,7 +103,7 @@ void SpanningTreeProtocolInterface::SendMode(User* source, User* u, Channel* c,
        }
 }
 
-void SpanningTreeProtocolInterface::SendSNONotice(const std::string &snomask, const std::string &text)
+void SpanningTreeProtocolInterface::SendSNONotice(char snomask, const std::string &text)
 {
        CmdBuilder("SNONOTICE").push(snomask).push_last(text).Broadcast();
 }
index 8b9eeb6a869f6b4fa870d65798bff36ebcf302ef..745a0c3cc2c3ff5cf2831f48eee7747e7350e175 100644 (file)
@@ -37,7 +37,7 @@ class SpanningTreeProtocolInterface : public ProtocolInterface
        void SendMetaData(const std::string& key, const std::string& data) CXX11_OVERRIDE;
        void SendTopic(Channel* channel, std::string &topic);
        void SendMode(User* source, User* usertarget, Channel* chantarget, const parameterlist& modedata, const std::vector<TranslateType>& types);
-       void SendSNONotice(const std::string &snomask, const std::string &text);
+       void SendSNONotice(char snomask, const std::string& text) CXX11_OVERRIDE;
        void PushToClient(User* target, const std::string &rawline);
        void SendMessage(Channel* target, char status, const std::string& text, MessageType msgtype);
        void SendMessage(User* target, const std::string& text, MessageType msgtype);
index d7cb64f26d45c5f46817049a0070ecc0b8cfa9df..e0305ea061330120fe1a575a5e0059b6eb93e1ea 100644 (file)
@@ -47,7 +47,7 @@ void SnomaskManager::WriteGlobalSno(char letter, const std::string& text)
 {
        WriteToSnoMask(letter, text);
        letter = toupper(letter);
-       ServerInstance->PI->SendSNONotice(std::string(1, letter), text);
+       ServerInstance->PI->SendSNONotice(letter, text);
 }
 
 void SnomaskManager::WriteToSnoMask(char letter, const char* text, ...)