mirror of https://github.com/python/cpython
f1827cfaab
file_truncate(): C doesn't define what fflush(fp) does if fp is open for update, and the preceding I/O operation on fp was input. On Windows, fflush() actually changes the current file position then. Because Windows doesn't support ftruncate() directly, this not only caused Python's file.truncate() to change the file position (contra our docs), it also caused the file not to change size. Repaired by getting the initial file position at the start, restoring it at the end, and tossing all the complicated micro-efficiency checks trying to avoid "provably unnecessary" seeks. file.truncate() can't be a frequent operation, and seeking to the current file position has got to be cheap anyway. Bugfix candidate. |
||
---|---|---|
.. | ||
RPM | ||
ACKS | ||
AIX-NOTES | ||
BeOS-NOTES | ||
BeOS-setup.py | ||
HISTORY | ||
NEWS | ||
NEWS.help | ||
PURIFY.README | ||
Porting | ||
README | ||
RFD | ||
SpecialBuilds.txt | ||
cheatsheet | ||
find_recursionlimit.py | ||
gdbinit | ||
indent.pro | ||
pymemcompat.h | ||
python-mode.el | ||
python.man | ||
setuid-prog.c | ||
vgrindefs |
README
Python Misc subdirectory ======================== This directory contains files that wouldn't fit in elsewhere. Some documents are only of historic importance. Files found here ---------------- ACKS Acknowledgements AIX-NOTES Notes for building Python on AIX BeOS-NOTES Notes for building on BeOS BeOS-setup.py setup.py replacement for BeOS, see BeOS-NOTES cheatsheet Quick summary of Python by Ken Manheimer find_recursionlimit.py Script to find a value for sys.maxrecursionlimit gdbinit Handy stuff to put in your .gdbinit file, if you use gdb HISTORY News from previous releases -- oldest last HPUX-NOTES Notes about dynamic loading under HP-UX indent.pro GNU indent profile approximating my C style NEWS News for this release (for some meaning of "this") Porting Mini-FAQ on porting to new platforms PURIFY.README Information for Purify users pymemcompat.h Memory interface compatibility file. python.man UNIX man page for the python interpreter python-mode.el Emacs mode for editing Python programs README The file you're reading now RFD Request For Discussion about a Python newsgroup RPM (Old) tools to build RPMs SpecialBuilds.txt Describes extra symbols you can set for debug builds setuid-prog.c C helper program for set-uid Python scripts vgrindefs Python configuration for vgrind (a generic pretty printer)