summaryrefslogtreecommitdiff
path: root/src/modules/m_chgident.cpp
diff options
context:
space:
mode:
authorspecial <special@e03df62e-2008-0410-955e-edbf42e46eb7>2007-06-26 06:33:41 +0000
committerspecial <special@e03df62e-2008-0410-955e-edbf42e46eb7>2007-06-26 06:33:41 +0000
commite4c1ae81efcfce5d5105c49bbb17356496e67ff1 (patch)
tree2fbb5c1bf9124f4dd072c7faf6d8ac18de145881 /src/modules/m_chgident.cpp
parentee6208dc8f5bb806eca36e230ca5bbb6d5a45f60 (diff)
Made all of the error messages in chg* and set* a bit more uniform, and added a few that were missing
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@7413 e03df62e-2008-0410-955e-edbf42e46eb7
Diffstat (limited to 'src/modules/m_chgident.cpp')
-rw-r--r--src/modules/m_chgident.cpp13
1 files changed, 10 insertions, 3 deletions
diff --git a/src/modules/m_chgident.cpp b/src/modules/m_chgident.cpp
index e3067fe56..a212077ed 100644
--- a/src/modules/m_chgident.cpp
+++ b/src/modules/m_chgident.cpp
@@ -40,12 +40,19 @@ class cmd_chgident : public command_t
if (!*parameters[1])
{
- user->WriteServ("NOTICE %s :*** CHGIDENT: Needs non-zero length ident", user->nick);
+ user->WriteServ("NOTICE %s :*** CHGIDENT: Ident must be specified", user->nick);
return CMD_FAILURE;
}
- if(!ServerInstance->IsIdent(parameters[1]))
+
+ if (strlen(parameters[1]) > IDENTMAX)
{
- user->WriteServ("NOTICE %s :*** Invalid characters in ident", user->nick);
+ user->WriteServ("NOTICE %s :*** CHGIDENT: Ident is too long", user->nick);
+ return CMD_FAILURE;
+ }
+
+ if (!ServerInstance->IsIdent(parameters[1]))
+ {
+ user->WriteServ("NOTICE %s :*** CHGIDENT: Invalid characters in ident", user->nick);
return CMD_FAILURE;
}