diff options
author | Daniel De Graaf <danieldg@inspircd.org> | 2010-09-04 19:30:44 -0400 |
---|---|---|
committer | Daniel De Graaf <danieldg@inspircd.org> | 2010-09-04 19:30:44 -0400 |
commit | 08895e2aa3c1bfe604cf85249ea2ee62743e73ff (patch) | |
tree | 6f8fe1c023052f7f16ce503c483d591955da926b /src/modes | |
parent | 3ee7abb7b9127edd8b730602376a9e827afb95f6 (diff) |
Do not apply parameter length restrictions or CleanMask when unsetting modes
Diffstat (limited to 'src/modes')
-rw-r--r-- | src/modes/cmode_b.cpp | 5 |
1 files changed, 1 insertions, 4 deletions
diff --git a/src/modes/cmode_b.cpp b/src/modes/cmode_b.cpp index 5fcebfde9..0bd8d286d 100644 --- a/src/modes/cmode_b.cpp +++ b/src/modes/cmode_b.cpp @@ -105,7 +105,7 @@ std::string& ModeChannelBan::AddBan(User *user, std::string &dest, Channel *chan /* Attempt to tidy the mask */ ModeParser::CleanMask(dest); /* If the mask was invalid, we exit */ - if (dest == "") + if (dest == "" || dest.length() > 250) return dest; long maxbans = chan->GetMaxBans(); @@ -150,9 +150,6 @@ std::string& ModeChannelBan::DelBan(User *user, std::string& dest, Channel *chan return dest; } - /* 'Clean' the mask, e.g. nick -> nick!*@* */ - ModeParser::CleanMask(dest); - for (BanList::iterator i = chan->bans.begin(); i != chan->bans.end(); i++) { if (!strcasecmp(i->data.c_str(), dest.c_str())) |