[Issue 18017] [External] [DMC] File.size() uses a 32-bit signed integer for size internally (gives wrong results for files over ≈2.1 GB)

d-bugmail at puremagic.com d-bugmail at puremagic.com
Tue Nov 28 21:25:46 UTC 2017


https://issues.dlang.org/show_bug.cgi?id=18017

kinke at gmx.net changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |kinke at gmx.net

--- Comment #6 from kinke at gmx.net ---
(In reply to Steven Schveighoffer from comment #5)
> std.stdio.File is based completely on libc's FILE * structure. It can only
> support whatever that supports, and that isn't very much. In the case of
> 32-bit windows, the library it uses is Digital Mars' C runtime, which has
> some difficult limitations, this being one of them.
> 
> A potential fix here is to get the handle directly from the FILE * and query
> it using WinAPI. But this doesn't fix File.tell(), which is going to use the
> libc version.

Then `-m32mscoff` is another option for Win32.

--


More information about the Digitalmars-d-bugs mailing list