summaryrefslogtreecommitdiff
path: root/src/modules/m_nationalchars.cpp
diff options
context:
space:
mode:
authorAttila Molnar <attilamolnar@hush.com>2013-05-18 12:03:55 -0700
committerAttila Molnar <attilamolnar@hush.com>2013-05-18 12:03:55 -0700
commit8f27fefa75e2952e7ab8757eb9fe4af4586817f0 (patch)
tree752def83ea80788d6a04fb8cc8358146915e7c4a /src/modules/m_nationalchars.cpp
parent143b2b081821f027eaa72be522ea691447980850 (diff)
parent5c9427cde0a949a17a476311db0a2a275345337b (diff)
Merge pull request #543 from SaberUK/master+sizeparam-removal
Remove the size argument from IsChannel and IsNick.
Diffstat (limited to 'src/modules/m_nationalchars.cpp')
-rw-r--r--src/modules/m_nationalchars.cpp12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/modules/m_nationalchars.cpp b/src/modules/m_nationalchars.cpp
index e39a41815..4e921957a 100644
--- a/src/modules/m_nationalchars.cpp
+++ b/src/modules/m_nationalchars.cpp
@@ -31,12 +31,12 @@
/* $ModDesc: Provides an ability to have non-RFC1459 nicks & support for national CASEMAPPING */
-class lwbNickHandler : public HandlerBase2<bool, const std::string&, size_t>
+class lwbNickHandler : public HandlerBase1<bool, const std::string&>
{
public:
lwbNickHandler() { }
~lwbNickHandler() { }
- bool Call(const std::string&, size_t);
+ bool Call(const std::string&);
};
/*,m_reverse_additionalUp[256];*/
@@ -71,7 +71,7 @@ char utf8size(unsigned char * mb)
/* Conditions added */
-bool lwbNickHandler::Call(const std::string& nick, size_t max)
+bool lwbNickHandler::Call(const std::string& nick)
{
if (nick.empty())
return false;
@@ -216,7 +216,7 @@ bool lwbNickHandler::Call(const std::string& nick, size_t max)
}
/* too long? or not -- pointer arithmetic rocks */
- return (p < max);
+ return (p < ServerInstance->Config->Limits.NickMax);
}
@@ -225,7 +225,7 @@ class ModuleNationalChars : public Module
lwbNickHandler myhandler;
std::string charset, casemapping;
unsigned char m_additional[256], m_additionalUp[256], m_lower[256], m_upper[256];
- caller2<bool, const std::string&, size_t> rememberer;
+ caller1<bool, const std::string&> rememberer;
bool forcequit;
const unsigned char * lowermap_rememberer;
@@ -274,7 +274,7 @@ class ModuleNationalChars : public Module
{
/* Fix by Brain: Dont quit UID users */
User* n = *iter;
- if (!isdigit(n->nick[0]) && !ServerInstance->IsNick(n->nick, ServerInstance->Config->Limits.NickMax))
+ if (!isdigit(n->nick[0]) && !ServerInstance->IsNick(n->nick))
ServerInstance->Users->QuitUser(n, message);
}
}