diff options
Diffstat (limited to 'src/cmd_nick.cpp')
-rw-r--r-- | src/cmd_nick.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/cmd_nick.cpp b/src/cmd_nick.cpp index a7472bd95..2ed79b434 100644 --- a/src/cmd_nick.cpp +++ b/src/cmd_nick.cpp @@ -25,6 +25,7 @@ #include "xline.h" #include "dns.h" #include "helperfuncs.h" +#include "inspircd.h" #include "hashcomp.h" #include "commands/cmd_nick.h" @@ -84,10 +85,11 @@ void cmd_nick::Handle (const char** parameters, int pcnt, userrec *user) { parameters[0]++; } - if (matches_qline(parameters[0])) + char* mq = ServerInstance->XLines->matches_qline(parameters[0]); + if (mq) { - ServerInstance->WriteOpers("*** Q-Lined nickname %s from %s!%s@%s: %s",parameters[0],user->nick,user->ident,user->host,matches_qline(parameters[0])); - user->WriteServ("432 %s %s :Invalid nickname: %s",user->nick,parameters[0],matches_qline(parameters[0])); + ServerInstance->WriteOpers("*** Q-Lined nickname %s from %s!%s@%s: %s",parameters[0],user->nick,user->ident,user->host,mq); + user->WriteServ("432 %s %s :Invalid nickname: %s",user->nick,parameters[0],mq); return; } if ((ServerInstance->FindNick(parameters[0])) && (ServerInstance->FindNick(parameters[0]) != user)) |