summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorAttila Molnar <attilamolnar@hush.com>2016-08-22 16:39:08 +0200
committerAttila Molnar <attilamolnar@hush.com>2016-08-22 16:39:08 +0200
commit76710ee4c6193c2c0f702c67ccb6ec68f0a1f315 (patch)
treeb226b01113d2fa30b647257ff5e1922a2dd98fb9 /src
parentadc366ab1dd3274855bc6abbfe256567825b232e (diff)
m_timedbans Remove one irc::string usage
Diffstat (limited to 'src')
-rw-r--r--src/modules/m_timedbans.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/modules/m_timedbans.cpp b/src/modules/m_timedbans.cpp
index 8a627b9a6..9a6824793 100644
--- a/src/modules/m_timedbans.cpp
+++ b/src/modules/m_timedbans.cpp
@@ -148,12 +148,13 @@ class BanWatcher : public ModeWatcher
return;
irc::string listitem = banmask.c_str();
- irc::string thischan = chan->name.c_str();
for (timedbans::iterator i = TimedBanList.begin(); i != TimedBanList.end(); ++i)
{
+ if (i->chan != chan)
+ continue;
+
irc::string target = i->mask.c_str();
- irc::string tchan = i->channel.c_str();
- if ((listitem == target) && (tchan == thischan))
+ if (listitem == target)
{
TimedBanList.erase(i);
break;