]> git.netwichtig.de Git - user/henk/code/inspircd.git/blobdiff - src/modules/m_banexception.cpp
Update the cloaks of connected users when their IP address changes.
[user/henk/code/inspircd.git] / src / modules / m_banexception.cpp
index b29b397475e5e304fb2e79b76e85e3713258a666..3905cdf6a08655d2d259138be56f078d5750e43d 100644 (file)
@@ -53,7 +53,7 @@ class ModuleBanException : public Module
 
        void On005Numeric(std::map<std::string, std::string>& tokens) CXX11_OVERRIDE
        {
-               tokens["EXCEPTS"] = "e";
+               tokens["EXCEPTS"] = ConvToStr(be.GetModeChar());
        }
 
        ModResult OnExtBanCheck(User *user, Channel *chan, char type) CXX11_OVERRIDE
@@ -64,7 +64,7 @@ class ModuleBanException : public Module
 
                for (ListModeBase::ModeList::iterator it = list->begin(); it != list->end(); it++)
                {
-                       if (it->mask[0] != type || it->mask[1] != ':')
+                       if (it->mask.length() <= 2 || it->mask[0] != type || it->mask[1] != ':')
                                continue;
 
                        if (chan->CheckBan(user, it->mask.substr(2)))