changeset eb0712345796 in /home/hg/repos/gajim
details:http://hg.gajim.org/gajim?cmd=changeset;node=eb0712345796 description: don't try only last_connection_type, but try it it first. Fixes #7002
diffstat:
src/common/connection.py | 9 ++++++--- 1 files changed, 6 insertions(+), 3 deletions(-)
diffs (23 lines):
diff -r 3bff619a66d2 -r eb0712345796 src/common/connection.py --- a/src/common/connection.py Sun Aug 19 14:46:42 2012 +0400 +++ b/src/common/connection.py Sun Aug 19 22:35:46 2012 +0200 @@ -1102,13 +1102,16 @@ log.debug('Connection to next host') if len(self._hosts): # No config option exist when creating a new account - if self.last_connection_type: - self._connection_types = [self.last_connection_type] - elif self.name in gajim.config.get_per('accounts'): + if self.name in gajim.config.get_per('accounts'): self._connection_types = gajim.config.get_per('accounts', self.name, 'connection_types').split() else: self._connection_types = ['tls', 'ssl', 'plain'] + if self.last_connection_type: + if self.last_connection_type in self._connection_types: + self._connection_types.remove(self.last_connection_type) + self._connection_types.insert(0, self.last_connection_type) +
if self._proxy and self._proxy['type']=='bosh': # with BOSH, we can't do TLS negotiation with <starttls>, we do only "plain"