summaryrefslogtreecommitdiffstats
path: root/Lib/tempfile.py
diff options
context:
space:
mode:
authorGeorg Brandl <georg@python.org>2007-10-22 12:42:46 (GMT)
committerGeorg Brandl <georg@python.org>2007-10-22 12:42:46 (GMT)
commit7816e5142732cca24dafc2863edbd818aada7dba (patch)
tree343ae1d92ca080c601788b73cf56fe28f27d7773 /Lib/tempfile.py
parent40d20bcf1fccfe8af2393f1aec88ba18e38d0bc1 (diff)
downloadcpython-7816e5142732cca24dafc2863edbd818aada7dba.zip
cpython-7816e5142732cca24dafc2863edbd818aada7dba.tar.gz
cpython-7816e5142732cca24dafc2863edbd818aada7dba.tar.bz2
Fix exception indexing.
Diffstat (limited to 'Lib/tempfile.py')
-rw-r--r--Lib/tempfile.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/tempfile.py b/Lib/tempfile.py
index ae2b77f..3b21ff2 100644
--- a/Lib/tempfile.py
+++ b/Lib/tempfile.py
@@ -201,7 +201,7 @@ def _get_default_tempdir():
del fp, fd
return dir
except (OSError, IOError) as e:
- if e[0] != _errno.EEXIST:
+ if e.args[0] != _errno.EEXIST:
break # no point trying more names in this directory
pass
raise IOError(_errno.ENOENT,