[issue16367] io.FileIO.readall() is not 64-bit safe on Windows

STINNER Victor report at bugs.python.org
Wed Oct 31 00:43:07 CET 2012


New submission from STINNER Victor:

The changeset 374dc910db33 fixed FileIO.readinto(), FileIO.write() and os.write() on Windows for issues #9015, #9611, but FileIO.readall() was not fixed and it has a similar bug.

It uses "int n;" to store the result of read(), so FileIO.readall() may also fail to read a file longer than 2 GB on other platforms.

Attached patch should fix both issues.

----------
components: Library (Lib)
files: fileio_readall.patch
keywords: patch
messages: 174244
nosy: haypo, pitrou
priority: normal
severity: normal
status: open
title: io.FileIO.readall() is not 64-bit safe on Windows
versions: Python 2.7, Python 3.2, Python 3.3, Python 3.4
Added file: http://bugs.python.org/file27802/fileio_readall.patch

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue16367>
_______________________________________


More information about the Python-bugs-list mailing list