Don't send 421 to unregistered clients, per RFC (thanks nenolod)

git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@8661 e03df62e-2008-0410-955e-edbf42e46eb7
This commit is contained in:
w00t 2008-01-08 10:35:07 +00:00
parent 25d1f76ca0
commit e7310ca2f6

View File

@ -290,7 +290,7 @@ bool CommandParser::ProcessCommand(User *user, std::string &cmd)
/* find the command, check it exists */
Commandable::iterator cm = cmdlist.find(command);
if (cm == cmdlist.end())
if (cm == cmdlist.end() && user->registered == REG_ALL)
{
ServerInstance->stats->statsUnknown++;
user->WriteServ("421 %s %s :Unknown command",user->nick,command.c_str());