diff options
Diffstat (limited to 'src/command_parse.cpp')
-rw-r--r-- | src/command_parse.cpp | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/src/command_parse.cpp b/src/command_parse.cpp index 8e704e796..1a32456b2 100644 --- a/src/command_parse.cpp +++ b/src/command_parse.cpp @@ -232,7 +232,12 @@ void CommandParser::ProcessCommand(userrec *user, std::string &cmd) if (items < cm->second->min_params) { log(DEBUG,"not enough parameters: %s %s",user->nick,command.c_str()); - WriteServ(user->fd,"461 %s %s :Not enough parameters",user->nick,command.c_str()); + + /* If syntax is given, display this as the 461 reply */ + if (cm->second->syntax.length()) + WriteServ(user->fd,"461 %s %s :Syntax: %s %s", cm->second->command.c_str(), cm->second->syntax.c_str()); + else + WriteServ(user->fd,"461 %s %s :Not enough parameters",user->nick,command.c_str()); return; } if (cm->second->flags_needed) |