Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
The Tor Project
Anti-censorship
BridgeDB
Commits
b659bbc7
Unverified
Commit
b659bbc7
authored
Jan 12, 2014
by
Isis Lovecruft
Browse files
Fix bug where open() was called even when COUNTY_BLOCK_FILE=None.
parent
87e44b44
Changes
1
Hide whitespace changes
Inline
Side-by-side
lib/bridgedb/Bucket.py
View file @
b659bbc7
...
...
@@ -222,7 +222,7 @@ class BucketManager:
# for a bridge, get the list of countries it might not work in
blocklist
=
dict
()
if
has
attr
(
self
.
cfg
,
"COUNTRY_BLOCK_FILE"
)
:
if
get
attr
(
self
.
cfg
,
"COUNTRY_BLOCK_FILE"
,
None
)
is
not
None
:
f
=
open
(
self
.
cfg
.
COUNTRY_BLOCK_FILE
,
'r'
)
for
ID
,
address
,
portlist
,
countries
in
bridgedb
.
Bridges
.
parseCountryBlockFile
(
f
):
blocklist
[
toHex
(
ID
)]
=
countries
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment