This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author vstinner
Recipients benjamin.peterson, hynek, josh.r, pitrou, steve.dower, stutzbach, tim.golden, vstinner, zach.ware
Date 2015-01-08.10:30:59
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1420713062.84.0.0550240741825.issue23152@psf.upfronthosting.co.za>
In-reply-to
Content
Here is a patch adding a new _Py_fstat() function which uses signed 64-bit integer to store the file size and so is not limited to 2 GB files. I just moved the code from posixmodule.c to fileutils.c.

The patch replaces calls to fstat() with _Py_stat() (and also change the stat structure to _Py_stat_struct).

I didn't modified _Py_stat() which calls _wstat() on Windows and so also have this issue (limited to 2 GB files on Windows). _Py_stat() is called in zipimport.c, so zipped packages are limited to 2 GB on Windows. I don't know if it's a severe issue or not. os.stat() implementation is more complex than os.fstat() on Windows.

I'm unable to test my patch on Windows because Visual Studio 2010 is unable to open the new PCbuild/pcbuild.sln: see my comment on the issue #22919.
History
Date User Action Args
2015-01-08 10:31:04vstinnersetrecipients: + vstinner, pitrou, tim.golden, benjamin.peterson, stutzbach, hynek, zach.ware, steve.dower, josh.r
2015-01-08 10:31:02vstinnersetmessageid: <1420713062.84.0.0550240741825.issue23152@psf.upfronthosting.co.za>
2015-01-08 10:31:02vstinnerlinkissue23152 messages
2015-01-08 10:30:59vstinnercreate