From d33055c3bc868a7126e5218739b4b07726f61328 Mon Sep 17 00:00:00 2001 From: Dimitur Kirov Date: Wed, 15 Mar 2006 21:06:22 +0000 Subject: [PATCH] don't try to connect, when we are in state 'connecting' --- src/common/connection.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/common/connection.py b/src/common/connection.py index e34634897..82e20c313 100644 --- a/src/common/connection.py +++ b/src/common/connection.py @@ -1821,6 +1821,7 @@ class Connection: if self.last_connection: self.last_connection.socket.disconnect() self.last_connection = None + self.connection = None if gajim.verbose: con = common.xmpp.NonBlockingClient(self._hostname, caller = self, on_connect = self.on_connect_success, @@ -2116,6 +2117,9 @@ class Connection: self._on_disconnected() elif show != 'offline' and self.connected: + # dont'try to connect, when we are in state 'connecting' + if self.connected == 1: + return was_invisible = self.connected == STATUS_LIST.index('invisible') self.connected = STATUS_LIST.index(show) if show == 'invisible':