aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Fabio Bas2010-06-15 09:02:33 +0000
committerGravatar Fabio Bas2010-06-15 09:02:33 +0000
commitac82765ef0b3e5bb575d3bc41e0831085ce71a54 (patch)
tree8473fe8b9313bb4e7ea744ce7720ef3f10cc4ae9
parentSome fixes (diff)
downloadKVIrc-ac82765ef0b3e5bb575d3bc41e0831085ce71a54.tar.gz
KVIrc-ac82765ef0b3e5bb575d3bc41e0831085ce71a54.tar.bz2
KVIrc-ac82765ef0b3e5bb575d3bc41e0831085ce71a54.zip
fixed login when identity profile are enabled but no matching profile exists, and the default nickname is already used on that network
git-svn-id: https://svn.kvirc.de/svn/trunk/kvirc@4465 17fca916-40b9-46aa-a4ea-0a15b648b75c
-rw-r--r--src/kvirc/sparser/kvi_sp_numeric.cpp8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/kvirc/sparser/kvi_sp_numeric.cpp b/src/kvirc/sparser/kvi_sp_numeric.cpp
index 78b0b1310..8e059d979 100644
--- a/src/kvirc/sparser/kvi_sp_numeric.cpp
+++ b/src/kvirc/sparser/kvi_sp_numeric.cpp
@@ -910,15 +910,19 @@ void KviServerParser::parseLoginNicknameProblem(KviIrcMessage *msg)
// Check for identity profiles
KviIdentityProfileSet * pSet = KviIdentityProfileSet::instance();
bool bProfilesEnabled = pSet ? (pSet->isEnabled() && !pSet->isEmpty()) : false;
+ KviIdentityProfile * pProfile = 0;
if(bProfilesEnabled)
{
- KviIdentityProfile * pProfile = pSet->findNetwork(msg->connection()->networkName());
+ pProfile = pSet->findNetwork(msg->connection()->networkName());
if(pProfile)
{
szNextNick = pProfile->altNick();
uNickCnt = 1;
}
- } else {
+ }
+
+ if(!pProfile)
+ {
switch(msg->connection()->stateData()->loginNickIndex())
{
case 0: