aboutsummaryrefslogtreecommitdiffstats
path: root/setuptools/command/sdist.py
diff options
context:
space:
mode:
authorJason R. Coombs <jaraco@jaraco.com>2015-01-04 11:35:16 -0500
committerJason R. Coombs <jaraco@jaraco.com>2015-01-04 11:35:16 -0500
commit9d6a6e5927ae0e67164383e419f3145fc154467e (patch)
tree8872d8b6de4c8706a5178dcb3dab2c9803216e59 /setuptools/command/sdist.py
parenta849ee957f3ba12945278f88e473eb3612faf4b9 (diff)
downloadexternal_python_setuptools-9d6a6e5927ae0e67164383e419f3145fc154467e.tar.gz
external_python_setuptools-9d6a6e5927ae0e67164383e419f3145fc154467e.tar.bz2
external_python_setuptools-9d6a6e5927ae0e67164383e419f3145fc154467e.zip
Use except/as, now supported by Python 2.6
Diffstat (limited to 'setuptools/command/sdist.py')
-rwxr-xr-xsetuptools/command/sdist.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/setuptools/command/sdist.py b/setuptools/command/sdist.py
index 3d33df80..851a1775 100755
--- a/setuptools/command/sdist.py
+++ b/setuptools/command/sdist.py
@@ -70,7 +70,8 @@ class sdist(orig.sdist):
try:
orig.sdist.read_template(self)
except:
- sys.exc_info()[2].tb_next.tb_frame.f_locals['template'].close()
+ _, _, tb = sys.exc_info()
+ tb.tb_next.tb_frame.f_locals['template'].close()
raise
# Beginning with Python 2.7.2, 3.1.4, and 3.2.1, this leaky file handle