diff options
author | Tarek Ziade <tarek@ziade.org> | 2011-08-20 11:52:00 +0200 |
---|---|---|
committer | Tarek Ziade <tarek@ziade.org> | 2011-08-20 11:52:00 +0200 |
commit | 2e6300e37739b614e8b4286a9c6f534305c1c005 (patch) | |
tree | 37b89d153c063e56753a7d8bc804875f31bb6cf9 /setuptools/command/easy_install.py | |
parent | 415e9dbe45360be9a592d5916e87cb16b1b023a4 (diff) | |
download | external_python_setuptools-2e6300e37739b614e8b4286a9c6f534305c1c005.tar.gz external_python_setuptools-2e6300e37739b614e8b4286a9c6f534305c1c005.tar.bz2 external_python_setuptools-2e6300e37739b614e8b4286a9c6f534305c1c005.zip |
don't use ternary operator - fixes #225
--HG--
branch : distribute
extra : rebase_source : ecff177a6be463bfc55c40deec0a3f1e2804e895
Diffstat (limited to 'setuptools/command/easy_install.py')
-rwxr-xr-x | setuptools/command/easy_install.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/setuptools/command/easy_install.py b/setuptools/command/easy_install.py index f44e8d4a..263b429c 100755 --- a/setuptools/command/easy_install.py +++ b/setuptools/command/easy_install.py @@ -1428,7 +1428,10 @@ def extract_wininst_cfg(dist_filename): part = f.read(cfglen) # part is in bytes, but we need to read up to the first null # byte. - null_byte = bytes([0]) if sys.version_info >= (2,6) else chr(0) + if sys.version_info >= (2,6): + null_byte = bytes([0]) + else: + chr(0) config = part.split(null_byte, 1)[0] # Now the config is in bytes, but on Python 3, it must be # unicode for the RawConfigParser, so decode it. Is this the |