[Python-3000-checkins] r58590 - python/branches/py3k/Lib/tempfile.py

georg.brandl python-3000-checkins at python.org
Mon Oct 22 14:42:47 CEST 2007


Author: georg.brandl
Date: Mon Oct 22 14:42:46 2007
New Revision: 58590

Modified:
   python/branches/py3k/Lib/tempfile.py
Log:
Fix exception indexing.


Modified: python/branches/py3k/Lib/tempfile.py
==============================================================================
--- python/branches/py3k/Lib/tempfile.py	(original)
+++ python/branches/py3k/Lib/tempfile.py	Mon Oct 22 14:42:46 2007
@@ -201,7 +201,7 @@
                 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,


More information about the Python-3000-checkins mailing list