diff options
Diffstat (limited to 'src/modules')
-rw-r--r-- | src/modules/m_joinflood.cpp | 1 | ||||
-rw-r--r-- | src/modules/m_messageflood.cpp | 6 |
2 files changed, 4 insertions, 3 deletions
diff --git a/src/modules/m_joinflood.cpp b/src/modules/m_joinflood.cpp index 983090d09..9ed3b1307 100644 --- a/src/modules/m_joinflood.cpp +++ b/src/modules/m_joinflood.cpp @@ -135,6 +135,7 @@ class JoinFlood : public ModeHandler else data++; } if (secs) + { /* Set up the flood parameters for this channel */ int njoins = atoi(joins); diff --git a/src/modules/m_messageflood.cpp b/src/modules/m_messageflood.cpp index be5dc68ae..9a9f684e5 100644 --- a/src/modules/m_messageflood.cpp +++ b/src/modules/m_messageflood.cpp @@ -144,7 +144,7 @@ class MsgFlood : public ModeHandler { if (!channel->GetExt("flood", f)) { - parameter = ConvToStr(nlines) + ":" +ConvToStr(nsecs); + parameter = std::string(ban ? "*" : "") + ConvToStr(nlines) + ":" +ConvToStr(nsecs); floodsettings *f = new floodsettings(ban,nsecs,nlines); channel->Extend("flood",f); channel->SetMode('f', true); @@ -153,11 +153,11 @@ class MsgFlood : public ModeHandler } else { - if (((nlines != f->lines) || (nsecs != f->secs)) && ((nsecs > 0) && (nlines > 0))) + if (((nlines != f->lines) || (nsecs != f->secs)) && ((nsecs > 0) && (nlines > 0)) || (ban != f->ban)) { delete f; floodsettings *f = new floodsettings(ban,nsecs,nlines); - parameter = ConvToStr(nlines) + ":" +ConvToStr(nsecs); + parameter = std::string(ban ? "*" : "") + ConvToStr(nlines) + ":" +ConvToStr(nsecs); channel->Shrink("flood"); channel->Extend("flood",f); channel->SetModeParam('f', parameter.c_str(), true); |