Bug 147473 - No nicknames from the identity were accepted by the connection
Summary: No nicknames from the identity were accepted by the connection
Status: RESOLVED FIXED
Alias: None
Product: konversation
Classification: Applications
Component: general (show other bugs)
Version: 1.0.1
Platform: unspecified Linux
: NOR normal
Target Milestone: ---
Assignee: argonel
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2007-07-03 02:27 UTC by Lars DIECKOW
Modified: 2008-04-20 18:33 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
patch (3.48 KB, patch)
2008-04-18 03:56 UTC, argonel
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Lars DIECKOW 2007-07-03 02:27:01 UTC
Version:           1.0.1 (using KDE 3.5.7 "release 10.1" , openSUSE )
Compiler:          Target: i586-suse-linux
OS:                Linux (i686) release 2.6.18.2-34-default

This is related to bug 131399 and possibly bug 85528.

How to reproduce:
For one identity, I have two nicks set up, foo and foo_. I connect to
the server using foo, then during the session change manually to foo_.
Later desaster strikes (for instance, the ISP's daily disconnect) and
I lose the connection to the server.

What should happen:
Konversation wraps around the list of defined nicks and picks the
first one again, foo. With this nick, it reconnects to the server.

What really happens:
Konversation thinks it is all out of nicks. It pops up the dialog
'No nicknames from the "%1" identity were accepted by the
connection "%2".'. Meanwhile there's no reconnect at all.

I enter foo as nick and confirm the dialog and the program reconnects
successfully. This proves that foo is really not in use, Konversation
just thinks it is.
Comment 1 argonel 2008-04-17 07:20:05 UTC
i think i've seen this as well, investigating
Comment 2 argonel 2008-04-18 03:56:43 UTC
Created attachment 24381 [details]
patch
Comment 3 argonel 2008-04-18 03:58:31 UTC
(sorry for the spam, did i mention the webform is stupid?)

So above is the fix for this, over-engineered: just the way I like it. This ensures we try each nickname we have at least once per reconnect. The old method assumed that the current nickname is #0, but sometimes the current nickname is one that was typed into Channel::nicknameCombobox or set with /nick. Since Channel::nicknameCombobox is a can of worms, I elected to leave it out of the equation.

I'd commit this right now except I know Eike has a big revamp of server.cpp on its way, so I defer the timing of this commit to him.
Comment 4 argonel 2008-04-20 18:33:10 UTC
SVN commit 799159 by argonel:

Now try all nicknames in the identity once and only once per reconnect attempt.
BUG: 147473


 M  +1 -1      chatwindow.cpp  
 M  +1 -1      chatwindow.h  
 M  +0 -1      inputfilter.h  
 M  +37 -3     server.cpp  
 M  +3 -2      server.h  


WebSVN link: http://websvn.kde.org/?view=rev&revision=799159