From: rl1987 Date: Fri, 14 Sep 2018 17:13:23 +0000 (+0300) Subject: Check Python version in test_rebind.py X-Git-Tag: tor-0.3.5.3-alpha~52^2~1 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d40b0e73c278cd54c6c4765f35b4d031a5882562;p=thirdparty%2Ftor.git Check Python version in test_rebind.py --- diff --git a/src/test/test_rebind.py b/src/test/test_rebind.py index 42a4658b49..7ba3a5796d 100644 --- a/src/test/test_rebind.py +++ b/src/test/test_rebind.py @@ -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()