diff options
author | Tres Seaver <tseaver@palladion.com> | 2012-12-30 23:45:44 -0500 |
---|---|---|
committer | Tres Seaver <tseaver@palladion.com> | 2012-12-30 23:45:44 -0500 |
commit | 2f8c8bd5de518bd1b42cb99f1a6644543520154b (patch) | |
tree | 1921a31ec74906821c3b8c66a0de7e118808ce37 | |
parent | 2a3d28cf5fed225bfe2c3f95dfbf61c2d23fd6c4 (diff) | |
download | external_python_setuptools-2f8c8bd5de518bd1b42cb99f1a6644543520154b.tar.gz external_python_setuptools-2f8c8bd5de518bd1b42cb99f1a6644543520154b.tar.bz2 external_python_setuptools-2f8c8bd5de518bd1b42cb99f1a6644543520154b.zip |
Close issue #341: 0.6.33 fails to build under python 2.40.6.34
--HG--
branch : distribute
extra : rebase_source : 065aad71143a72cb6abd3064e0e947fc4568422f
-rw-r--r-- | CHANGES.txt | 6 | ||||
-rw-r--r-- | pkg_resources.py | 11 |
2 files changed, 12 insertions, 5 deletions
diff --git a/CHANGES.txt b/CHANGES.txt index ebc2bdcc..1b248108 100644 --- a/CHANGES.txt +++ b/CHANGES.txt @@ -2,6 +2,12 @@ CHANGES ======= +---------- +Unreleased +---------- + ++ Issue #341: 0.6.33 fails to build under python 2.4 + ------ 0.6.33 ------ diff --git a/pkg_resources.py b/pkg_resources.py index cb8d3dcf..49aab675 100644 --- a/pkg_resources.py +++ b/pkg_resources.py @@ -1763,13 +1763,14 @@ def find_on_path(importer, path_item, only=False): elif not only and lower.endswith('.egg-link'): entry_file = open(os.path.join(path_item, entry)) try: - for line in entry_file: - if not line.strip(): continue - for item in find_distributions(os.path.join(path_item,line.rstrip())): - yield item - break + entry_lines = entry_file.readlines() finally: entry_file.close() + for line in entry_lines: + if not line.strip(): continue + for item in find_distributions(os.path.join(path_item,line.rstrip())): + yield item + break register_finder(ImpWrapper,find_on_path) if importlib_bootstrap is not None: |