mirror of
https://github.com/AdaCore/cpython.git
synced 2026-02-12 12:57:15 -08:00
Fix for issue #16800: Use buffered write to handle EINTR.
This commit is contained in:
@@ -177,8 +177,8 @@ def _get_default_tempdir():
|
||||
fd = _os.open(filename, _bin_openflags, 0o600)
|
||||
try:
|
||||
try:
|
||||
fp = _io.open(fd, 'wb', buffering=0, closefd=False)
|
||||
fp.write(b'blat')
|
||||
with _io.open(fd, 'wb', closefd=False) as fp:
|
||||
fp.write(b'blat')
|
||||
finally:
|
||||
_os.close(fd)
|
||||
finally:
|
||||
|
||||
Reference in New Issue
Block a user