Author: brett.cannon
Date: Mon Aug 6 00:23:10 2007
New Revision: 56757
Modified:
python/branches/py3k-struni/Lib/tempfile.py
python/branches/py3k-struni/Misc/ACKS
Log:
Move tempfile over to the io module. Makes test_threaded_import pass.
Thanks Paul Colomiets.
Modified: python/branches/py3k-struni/Lib/tempfile.py
==============================================================================
--- python/branches/py3k-struni/Lib/tempfile.py (original)
+++ python/branches/py3k-struni/Lib/tempfile.py Mon Aug 6 00:23:10 2007
@@ -197,7 +197,7 @@
filename = _os.path.join(dir, name)
try:
fd = _os.open(filename, flags, 0o600)
- fp = _os.fdopen(fd, 'w')
+ fp = _io.open(fd, 'w')
fp.write('blat')
fp.close()
_os.unlink(filename)
@@ -438,7 +438,7 @@
flags |= _os.O_TEMPORARY
(fd, name) = _mkstemp_inner(dir, prefix, suffix, flags)
- file = _os.fdopen(fd, mode, bufsize)
+ file = _io.open(fd, mode, bufsize)
return _TemporaryFileWrapper(file, name, delete)
if _os.name != 'posix' or _os.sys.platform == 'cygwin':
@@ -471,7 +471,7 @@
(fd, name) = _mkstemp_inner(dir, prefix, suffix, flags)
try:
_os.unlink(name)
- return _os.fdopen(fd, mode, bufsize)
+ return _io.open(fd, mode, bufsize)
except:
_os.close(fd)
raise
Modified: python/branches/py3k-struni/Misc/ACKS
==============================================================================
--- python/branches/py3k-struni/Misc/ACKS (original)
+++ python/branches/py3k-struni/Misc/ACKS Mon Aug 6 00:23:10 2007
@@ -134,6 +134,7 @@
Dave Cole
Benjamin Collar
Jeffery Collins
+Paul Colomiets
Matt Conway
David M. Cooke
Greg Copeland
_______________________________________________
Python-3000-checkins mailing list
[email protected]
http://mail.python.org/mailman/listinfo/python-3000-checkins