[tor-commits] [ooni-probe/master] Fix bug inside of oonibclient spotted in unittesting.
art at torproject.org
art at torproject.org
Fri Feb 28 14:32:21 UTC 2014
commit 95d67f74773b83e31a9da903b89581f2075d115d
Author: Arturo Filastò <art at fuffa.org>
Date: Fri Jan 31 13:51:43 2014 +0100
Fix bug inside of oonibclient spotted in unittesting.
---
ooni/oonibclient.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/ooni/oonibclient.py b/ooni/oonibclient.py
index be5804f..84e12b5 100644
--- a/ooni/oonibclient.py
+++ b/ooni/oonibclient.py
@@ -103,6 +103,9 @@ class OONIBClient(object):
def genReceiver(finished, content_length):
def process_response(s):
+ # If empty string then don't parse it.
+ if not s:
+ return
try:
response = json.loads(s)
except ValueError:
More information about the tor-commits
mailing list