]> git.ipfire.org Git - thirdparty/tor.git/commitdiff
Check Python version in test_rebind.py
authorrl1987 <rl1987@sdf.lonestar.org>
Fri, 14 Sep 2018 17:13:23 +0000 (20:13 +0300)
committerrl1987 <rl1987@sdf.lonestar.org>
Fri, 21 Sep 2018 07:57:41 +0000 (10:57 +0300)
src/test/test_rebind.py

index 42a4658b494e9737f5a01f80c20687241acaa9e9..7ba3a5796d34cc53370150ec4c6062dea8ce98c0 100644 (file)
@@ -35,6 +35,12 @@ def pick_random_port():
 
     return port
 
+if sys.hexversion < 0x02070000:
+    sys.exit("ERROR: unsupported Python version (should be >= 2.7)")
+
+if sys.hexversion > 0x03000000 and sys.hexversion < 0x03010000:
+    sys.exit("ERROR: unsupported Python3 version (should be >= 3.1)")
+
 control_port = pick_random_port()
 socks_port = pick_random_port()