summaryrefslogtreecommitdiff
path: root/src/modules
diff options
context:
space:
mode:
authordanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-04-29 02:43:16 +0000
committerdanieldg <danieldg@e03df62e-2008-0410-955e-edbf42e46eb7>2009-04-29 02:43:16 +0000
commitd2a71fd3447c8bac65cc26077e2b9fc3fb0b28a7 (patch)
tree648fcf8fa6ca20ab599d618fd33433a761639d98 /src/modules
parent1064b6732975ad32ac32147974a3af2d888a7e12 (diff)
Overloading SetMode seems to cause the compiler to interpret "" as a bool and not a string. Fixes bug #849
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@11335 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules')
-rw-r--r--src/modules/m_joinflood.cpp6
-rw-r--r--src/modules/m_kicknorejoin.cpp6
-rw-r--r--src/modules/m_messageflood.cpp6
-rw-r--r--src/modules/m_nickflood.cpp6
-rw-r--r--src/modules/m_redirect.cpp4
5 files changed, 14 insertions, 14 deletions
diff --git a/src/modules/m_joinflood.cpp b/src/modules/m_joinflood.cpp
index 7e4a05d2b..cb8c90e09 100644
--- a/src/modules/m_joinflood.cpp
+++ b/src/modules/m_joinflood.cpp
@@ -144,7 +144,7 @@ class JoinFlood : public ModeHandler
parameter = ConvToStr(njoins) + ":" +ConvToStr(nsecs);
joinfloodsettings *f = new joinfloodsettings(ServerInstance, nsecs, njoins);
channel->Extend("joinflood", f);
- channel->SetMode('j', parameter);
+ channel->SetModeParam('j', parameter);
return MODEACTION_ALLOW;
}
else
@@ -167,7 +167,7 @@ class JoinFlood : public ModeHandler
f = new joinfloodsettings(ServerInstance, nsecs, njoins);
channel->Shrink("joinflood");
channel->Extend("joinflood", f);
- channel->SetMode('j', parameter);
+ channel->SetModeParam('j', parameter);
return MODEACTION_ALLOW;
}
else
@@ -192,7 +192,7 @@ class JoinFlood : public ModeHandler
channel->GetExt("joinflood", f);
delete f;
channel->Shrink("joinflood");
- channel->SetMode('j', "");
+ channel->SetModeParam('j', "");
return MODEACTION_ALLOW;
}
}
diff --git a/src/modules/m_kicknorejoin.cpp b/src/modules/m_kicknorejoin.cpp
index c5abc80c2..9e12b4e18 100644
--- a/src/modules/m_kicknorejoin.cpp
+++ b/src/modules/m_kicknorejoin.cpp
@@ -65,7 +65,7 @@ class KickRejoin : public ModeHandler
}
else
{
- channel->SetMode('J', "");
+ channel->SetModeParam('J', "");
return MODEACTION_ALLOW;
}
}
@@ -74,7 +74,7 @@ class KickRejoin : public ModeHandler
if (!channel->IsModeSet('J'))
{
parameter = ConvToStr(atoi(parameter.c_str()));
- channel->SetMode('J', parameter);
+ channel->SetModeParam('J', parameter);
return MODEACTION_ALLOW;
}
else
@@ -91,7 +91,7 @@ class KickRejoin : public ModeHandler
parameter = ConvToStr(atoi(parameter.c_str()));
if (parameter != "0")
{
- channel->SetMode('J', parameter);
+ channel->SetModeParam('J', parameter);
return MODEACTION_ALLOW;
}
else
diff --git a/src/modules/m_messageflood.cpp b/src/modules/m_messageflood.cpp
index fb9d2bbc2..2342870b8 100644
--- a/src/modules/m_messageflood.cpp
+++ b/src/modules/m_messageflood.cpp
@@ -143,7 +143,7 @@ class MsgFlood : public ModeHandler
parameter = std::string(ban ? "*" : "") + ConvToStr(nlines) + ":" +ConvToStr(nsecs);
floodsettings *fs = new floodsettings(ServerInstance,ban,nsecs,nlines);
channel->Extend("flood",fs);
- channel->SetMode('f', parameter);
+ channel->SetModeParam('f', parameter);
return MODEACTION_ALLOW;
}
else
@@ -163,7 +163,7 @@ class MsgFlood : public ModeHandler
floodsettings *fs = new floodsettings(ServerInstance,ban,nsecs,nlines);
channel->Shrink("flood");
channel->Extend("flood",fs);
- channel->SetMode('f', parameter);
+ channel->SetModeParam('f', parameter);
return MODEACTION_ALLOW;
}
else
@@ -187,7 +187,7 @@ class MsgFlood : public ModeHandler
{
delete f;
channel->Shrink("flood");
- channel->SetMode('f', "");
+ channel->SetModeParam('f', "");
return MODEACTION_ALLOW;
}
}
diff --git a/src/modules/m_nickflood.cpp b/src/modules/m_nickflood.cpp
index 0a8e9a31d..81f5d9ea9 100644
--- a/src/modules/m_nickflood.cpp
+++ b/src/modules/m_nickflood.cpp
@@ -144,7 +144,7 @@ class NickFlood : public ModeHandler
parameter = ConvToStr(nnicks) + ":" +ConvToStr(nsecs);
nickfloodsettings *f = new nickfloodsettings(ServerInstance, nsecs, nnicks);
channel->Extend("nickflood", f);
- channel->SetMode('F', parameter);
+ channel->SetModeParam('F', parameter);
return MODEACTION_ALLOW;
}
else
@@ -167,7 +167,7 @@ class NickFlood : public ModeHandler
f = new nickfloodsettings(ServerInstance, nsecs, nnicks);
channel->Shrink("nickflood");
channel->Extend("nickflood", f);
- channel->SetMode('F', parameter);
+ channel->SetModeParam('F', parameter);
return MODEACTION_ALLOW;
}
else
@@ -192,7 +192,7 @@ class NickFlood : public ModeHandler
channel->GetExt("nickflood", f);
delete f;
channel->Shrink("nickflood");
- channel->SetMode('F', "");
+ channel->SetModeParam('F', "");
return MODEACTION_ALLOW;
}
}
diff --git a/src/modules/m_redirect.cpp b/src/modules/m_redirect.cpp
index 00c191d26..8e66060b8 100644
--- a/src/modules/m_redirect.cpp
+++ b/src/modules/m_redirect.cpp
@@ -68,14 +68,14 @@ class Redirect : public ModeHandler
* We used to do some checking for circular +L here, but there is no real need for this any more especially as we
* now catch +L looping in PreJoin. Remove it, since O(n) logic makes me sad, and we catch it anyway. :) -- w00t
*/
- channel->SetMode('L', parameter);
+ channel->SetModeParam('L', parameter);
return MODEACTION_ALLOW;
}
else
{
if (channel->IsModeSet('L'))
{
- channel->SetMode('L', "");
+ channel->SetModeParam('L', "");
return MODEACTION_ALLOW;
}
}