Permalink
Browse files

Fix changing client nick when client connects.

If nicks are equal, it's not changed. The problem was that equality was
checked case-insensitively.

This makes some clients which compare nicks case-sensitively think that
JOINs which we send to them, are not related to the user, it's someone
else joining. So Konversation users which have lower case version of
their IRC nick configured in Konversation settings, didn't get their
channel opened when connecting to ZNC.

Thanks to Axanon for helping to investigate the issue.
  • Loading branch information...
1 parent 0250462 commit 390957723c0eae181587b29fd5ef7898ef947eb4 @DarthGandalf DarthGandalf committed Dec 25, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 src/IRCNetwork.cpp
View
@@ -468,7 +468,7 @@ void CIRCNetwork::ClientConnected(CClient *pClient) {
}
const CNick& Nick = GetIRCNick();
- if (!sClientNick.Equals(Nick.GetNick())) {
+ if (sClientNick != Nick.GetNick()) { // case-sensitive match
pClient->PutClient(":" + sClientNick + "!" + Nick.GetIdent() +
"@" + Nick.GetHost() + " NICK :" + Nick.GetNick());
pClient->SetNick(Nick.GetNick());

0 comments on commit 3909577

Please sign in to comment.