summaryrefslogtreecommitdiff
path: root/src/modules/m_chgname.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/m_chgname.cpp')
-rw-r--r--src/modules/m_chgname.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/modules/m_chgname.cpp b/src/modules/m_chgname.cpp
index 194ecf80e..667ddd928 100644
--- a/src/modules/m_chgname.cpp
+++ b/src/modules/m_chgname.cpp
@@ -44,6 +44,12 @@ class CommandChgname : public Command
return CMD_FAILURE;
}
+ if (parameters[1].empty())
+ {
+ user->WriteServ("NOTICE %s :*** CHGNAME: GECOS must be specified", user->nick.c_str());
+ return CMD_FAILURE;
+ }
+
if (parameters[1].length() > ServerInstance->Config->Limits.MaxGecos)
{
user->WriteServ("NOTICE %s :*** GECOS too long", user->nick.c_str());