summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Powell <petpow@saberuk.com>2017-09-02 19:53:48 +0100
committerPeter Powell <petpow@saberuk.com>2017-09-06 12:08:56 +0100
commit5a3f8af9f963b164832fabc1163611a2b768a890 (patch)
tree372d73dc73c363e2333964bd0fffa937dc8c39c5
parentb13b1b8a0613e48013ca9f6a5279559d0aee0f73 (diff)
Move RPL_SYNTAX to 650 to prevent a collision with RPL_TEXT.
Also move the command name to a parameter so that it is more easily parseable by software.
-rw-r--r--include/numerics.h3
-rw-r--r--src/command_parse.cpp2
2 files changed, 3 insertions, 2 deletions
diff --git a/include/numerics.h b/include/numerics.h
index a105b970e..2dc8d8414 100644
--- a/include/numerics.h
+++ b/include/numerics.h
@@ -73,7 +73,6 @@ enum
RPL_AWAY = 301,
RPL_USERHOST = 302,
RPL_ISON = 303,
- RPL_SYNTAX = 304, // insp-specific
RPL_UNAWAY = 305,
RPL_NOWAWAY = 306,
@@ -187,6 +186,8 @@ enum
ERR_CANTJOINOPERSONLY = 520, // unrealircd, but crap to have so many numerics for cant join..
ERR_CANTSENDTOUSER = 531, // ???
+ RPL_SYNTAX = 650, // insp-specific
+
ERR_CHANOPEN = 713,
ERR_KNOCKONCHAN = 714,
diff --git a/src/command_parse.cpp b/src/command_parse.cpp
index f3511b05b..9ffd20865 100644
--- a/src/command_parse.cpp
+++ b/src/command_parse.cpp
@@ -307,7 +307,7 @@ void CommandParser::ProcessCommand(LocalUser *user, std::string &cmd)
user->CommandFloodPenalty += failpenalty;
user->WriteNumeric(ERR_NEEDMOREPARAMS, command, "Not enough parameters.");
if ((ServerInstance->Config->SyntaxHints) && (user->registered == REG_ALL) && (handler->syntax.length()))
- user->WriteNumeric(RPL_SYNTAX, InspIRCd::Format("SYNTAX %s %s", handler->name.c_str(), handler->syntax.c_str()));
+ user->WriteNumeric(RPL_SYNTAX, handler->name, handler->syntax);
return;
}