From 922cce65585fa57862c04b3f57dd2d827792eee0 Mon Sep 17 00:00:00 2001 From: David Nichols Date: Fri, 12 Jul 2013 13:42:11 -0500 Subject: [PATCH] Initializing sockslisten config value to account for upgrades. Otherwise, settings panel will not load. --- src/helper_startup.py | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/helper_startup.py b/src/helper_startup.py index 3cde6805..aaf71709 100644 --- a/src/helper_startup.py +++ b/src/helper_startup.py @@ -78,3 +78,9 @@ def loadConfig(): os.makedirs(shared.appdata) with open(shared.appdata + 'keys.dat', 'wb') as configfile: shared.config.write(configfile) + + # Initialize settings that may be missing due to upgrades and could + # cause errors if missing. + if not shared.config.has_option('bitmessagesettings', 'sockslisten'): + shared.config.set('bitmessagesettings', 'sockslisten', 'false') +