From 5e5fd150c6b97afa469b9c1ad0e0411b9bda958e Mon Sep 17 00:00:00 2001 From: Yann Leboulanger Date: Tue, 2 Aug 2011 10:38:51 +0200 Subject: [PATCH] don't set use_stun_server as True by default. It's useless when there is no stun server configured. Fixes #6935 --- src/common/config.py | 2 +- src/common/defs.py | 2 +- src/common/optparser.py | 7 +++++++ 3 files changed, 9 insertions(+), 2 deletions(-) diff --git a/src/common/config.py b/src/common/config.py index 84562468f..1b8579ba1 100644 --- a/src/common/config.py +++ b/src/common/config.py @@ -287,7 +287,7 @@ class Config: 'video_size': [opt_str, '', _('Optionally resize jingle output video. Example: 320x240')], 'audio_input_volume': [opt_int, 50], 'audio_output_volume': [opt_int, 50], - 'use_stun_server': [opt_bool, True, _('If True, Gajim will try to use a STUN server when using jingle. The one in "stun_server" option, or the one given by the jabber server.')], + 'use_stun_server': [opt_bool, False, _('If True, Gajim will try to use a STUN server when using jingle. The one in "stun_server" option, or the one given by the jabber server.')], 'stun_server': [opt_str, '', _('STUN server to use when using jingle')], 'show_affiliation_in_groupchat': [opt_bool, True, _('If True, Gajim will show affiliation of groupchat occupants by adding a colored square to the status icon')], } diff --git a/src/common/defs.py b/src/common/defs.py index 885de925d..e5f286a32 100644 --- a/src/common/defs.py +++ b/src/common/defs.py @@ -27,7 +27,7 @@ docdir = '../' basedir = '../' localedir = '../po' -version = '0.14.1.1' +version = '0.14.90.0' import subprocess try: node = subprocess.Popen('hg tip --template "{node|short}"', shell=True, diff --git a/src/common/optparser.py b/src/common/optparser.py index 606196086..65a1afba7 100644 --- a/src/common/optparser.py +++ b/src/common/optparser.py @@ -224,6 +224,8 @@ class OptionsParser: self.update_config_to_013901() if old < [0, 14, 0, 1] and new >= [0, 14, 0, 1]: self.update_config_to_01401() + if old < [0, 14, 90, 0] and new >= [0, 14, 90, 0]: + self.update_config_to_014900() gajim.logger.init_vars() gajim.logger.attach_cache_database() @@ -904,3 +906,8 @@ class OptionsParser: gajim.config.set('autodetect_browser_mailer', True) gajim.config.set('openwith', gajim.config.DEFAULT_OPENWITH) gajim.config.set('version', '0.14.0.1') + + def update_config_to_014900(self): + if 'use_stun_server' in self.old_values and self.old_values[ + 'use_stun_server'] and not self.old_values['stun_server']: + gajim.config.set('use_stun_server', False)