]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_ircv3_ctctags.cpp
Some more text fixes and improvements (#1618).
[user/henk/code/inspircd.git] / src / modules / m_ircv3_ctctags.cpp
index 8684642c675c0fd08583b276ed4954a6ab06a9cd..6052051b9a23787f91f3e761522f92885c92af0f 100644 (file)
@@ -83,7 +83,7 @@ class CommandTagMsg : public Command
                        if (no_chan_priv && chan->IsModeSet(moderatedmode))
                        {
                                // The moderated mode is set and the source has no status rank.
-                               source->WriteNumeric(ERR_CANNOTSENDTOCHAN, chan->name, "Cannot send to channel (+m)");
+                               source->WriteNumeric(ERR_CANNOTSENDTOCHAN, chan->name, "Cannot send to channel (+m is set)");
                                return CMD_FAILURE;
                        }
 
@@ -280,7 +280,7 @@ class C2CTags : public ClientProtocol::MessageTagProvider
        {
                // A client-only tag is prefixed with a plus sign (+) and otherwise conforms
                // to the format specified in IRCv3.2 tags.
-               if (tagname[0] != '+')
+               if (tagname[0] != '+' || tagname.length() < 2)
                        return MOD_RES_PASSTHRU;
 
                // If the user is local then we check whether they have the message-tags cap