summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/cmd_nick.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/cmd_nick.cpp b/src/cmd_nick.cpp
index 8240e5805..f35a8fd8c 100644
--- a/src/cmd_nick.cpp
+++ b/src/cmd_nick.cpp
@@ -90,9 +90,12 @@ void cmd_nick::Handle (char **parameters, int pcnt, userrec *user)
log(DEBUG,"invalid old nick passed to handle_nick");
return;
}
- if (!strcasecmp(user->nick,parameters[0]))
+ if (irc::string(user->nick) == irc::string(parameters[0]))
{
log(DEBUG,"old nick is new nick, skipping");
+ strlcpy(user->nick,parameters[0],NICKMAX);
+ if (user->registered == 7)
+ WriteCommon(user,"NICK %s",parameters[0]);
return;
}
else