Always send disconnected() on socket errors
authorManuel Nickschas <sputnick@quassel-irc.org>
Thu, 7 Nov 2013 22:03:06 +0000 (23:03 +0100)
committerManuel Nickschas <sputnick@quassel-irc.org>
Thu, 7 Nov 2013 22:43:25 +0000 (23:43 +0100)
commitbaacb468d9e2da5ed57cd064045dd9ddf1f7fbc9
treeedc58865bd7e9243be18766c5973cdea4714a97d
parent64cf9f9b8a737dad5f29447805d4004cfd03c454
Always send disconnected() on socket errors

Some socket errors (e.g. connection refused) don't trigger a disconnected()
from the socket, mostly because the socket hadn't been opened in the
first place.

To simplify the logic elsewhere, let's always send (exactly) one disconnected()
from the AuthHandler in case of socket errors. That way, we don't have to
introduce the mess we used to have in the reconnection logic in CoreConnection.
src/common/authhandler.cpp
src/common/authhandler.h