[tor-commits] [bridgedb/master] Fix a bug where bridgedb.Main only opens one extra-info file, not both.
isis at torproject.org
isis at torproject.org
Sun Jan 12 06:06:31 UTC 2014
commit 7cf1f52a76020d928e3ee598610afe382fd25c7e
Author: Isis Lovecruft <isis at torproject.org>
Date: Tue Nov 5 05:51:41 2013 +0000
Fix a bug where bridgedb.Main only opens one extra-info file, not both.
The old config item, EXTRA_INFO_FILE, was changed to a list, EXTRA_INFO_FILES,
some time ago, in commit 5c86df37fa1938508144bb52c971a3c31be0b310. However,
the config item searched for in bridgedb.Main was not, causing the extra-info
descriptor files not to be read.
* CHANGE bridgedb.Main to read extra-info descriptor filenames from
EXTRA_INFO_FILES config setting, not EXTRA_INFO_FILE.
* FIXES bug causing extra-info files not to be read.
---
lib/bridgedb/Main.py | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/lib/bridgedb/Main.py b/lib/bridgedb/Main.py
index 27b1339..5479d6a 100644
--- a/lib/bridgedb/Main.py
+++ b/lib/bridgedb/Main.py
@@ -131,8 +131,9 @@ def load(cfg, splitter, clear=False):
# read pluggable transports from extra-info document
# XXX: should read from networkstatus after bridge-authority
# does a reachability test
- logging.info("Opening extra-info document: '%s'" % cfg.EXTRA_INFO_FILE)
- f = open(cfg.EXTRA_INFO_FILE, 'r')
+ for filename in cfg.EXTRA_INFO_FILES:
+ logging.info("Opening extra-info document: '%s'" % filename)
+ f = open(filename, 'r')
for transport in Bridges.parseExtraInfoFile(f):
ID, method_name, address, port, argdict = transport
if bridges[ID].running:
More information about the tor-commits
mailing list