[issue1330] Fix truncate on Windows, this time for real

2007-10-26 Thread Guido van Rossum
Guido van Rossum added the comment: Committed revision 58673. I made one change, hopefully I didn't screw it up: skip the positional restore if the truncation itself failed. Otherwise the positional restore might overwrite the error from the truncation. After an error from this function they s

[issue1330] Fix truncate on Windows, this time for real

2007-10-25 Thread Christian Heimes
Christian Heimes added the comment: > While I like fixing the position restore in _fileio.c, I also liked > Amaury's flush() call in _BufferedIOMixin. Perhaps you can keep that > part (while losing the position restore)? Good point. We have to call flush() in _BufferedIOMixin as you said. I che

[issue1330] Fix truncate on Windows, this time for real

2007-10-25 Thread Guido van Rossum
Guido van Rossum added the comment: While I like fixing the position restore in _fileio.c, I also liked Amaury's flush() call in _BufferedIOMixin. Perhaps you can keep that part (while losing the position restore)? __ Tracker <[EMAIL PROTECTED]>

[issue1330] Fix truncate on Windows, this time for real

2007-10-25 Thread Guido van Rossum
Changes by Guido van Rossum: -- assignee: -> gvanrossum keywords: +patch, py3k __ Tracker <[EMAIL PROTECTED]> __ ___ Python-bugs-list mailing l

[issue1330] Fix truncate on Windows, this time for real

2007-10-25 Thread Christian Heimes
Changes by Christian Heimes: -- nosy: +gvanrossum, nnorwitz __ Tracker <[EMAIL PROTECTED]> __ ___ Python-bugs-list mailing list Unsubscribe: h

[issue1330] Fix truncate on Windows, this time for real

2007-10-25 Thread Christian Heimes
New submission from Christian Heimes: The patch fixes for real what "Patch # 1323 by Amaury Forgeot d'Arc" claims to have fixed. I reverted his patch to io.py and implemented the fix in the Windows specific part of truncate in _fileio.c. It fixes two tests for raw io on Windows. -- compo