diff options
author | Michael Elkins <melkins@tislabs.com> | 2011-01-13 22:47:21 +0000 |
---|---|---|
committer | Michael Elkins <melkins@tislabs.com> | 2011-01-13 22:47:21 +0000 |
commit | 91bb960e169cfad6e6ceb44f73e807e143d3b1e9 (patch) | |
tree | 2f3ae0f2a7b202c60a7d72702887ec9276063625 | |
parent | b6af810b75464bb271291181e97178a4bee35841 (diff) |
Allow rpkidemo to run under python 2.6+ instead of just 2.6 (needed for python 2.7 on some systems now)
svn path=/scripts/rpkidemo; revision=3607
-rwxr-xr-x | scripts/rpkidemo | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/scripts/rpkidemo b/scripts/rpkidemo index f02b1cc3..217d0b38 100755 --- a/scripts/rpkidemo +++ b/scripts/rpkidemo @@ -47,7 +47,7 @@ import sys python_version = sys.version_info[:2] -have_ssl_module = python_version == (2, 6) +have_ssl_module = python_version >= (2, 6) if python_version == (2, 5): print """ @@ -69,15 +69,15 @@ if python_version == (2, 5): else: print 'Please answer "yes" or "no"' -elif python_version == (2, 6): +elif have_ssl_module: try: import ssl except ImportError: - sys.exit("You're running Python 2.6, but I can't find the ssl module, so you have no SSL support at all, argh!") + sys.exit("You're running Python 2.6+, but I can't find the ssl module, so you have no SSL support at all, argh!") else: - sys.exit("Sorry, this script requires Python 2.6, I seem to be running in %s" % sys.version) + sys.exit("Sorry, this script requires Python 2.6+, I seem to be running in %s" % sys.version) # Ok, it's safe to import the other stuff we need now |