[Bug 43947] Disk size in Wine is not correct

WineHQ Bugzilla wine-bugs at winehq.org
Thu Oct 8 13:51:31 CDT 2020


https://bugs.winehq.org/show_bug.cgi?id=43947

--- Comment #15 from Alan A. <grsfdhj at tiscali.it> ---
Created attachment 68362
  --> https://bugs.winehq.org/attachment.cgi?id=68362
first fix for wrong disk sizes

This patch fixes the problem on my system by assuming that what
`GetDiskFreeSpaceExA` returns could be a ULONGLONG and then invoking
`StrFormatByteSize64A` instead of `StrFormatByteSizeA`.
Turns out that the "4Gib capping" seems due to only passing to the
`StrFormatByteSizeA` function the `LowPart` (which is a single DWORD/int32)
part of the `ulBytes` variable.

This is just a first try at solving the problem, though. I don't know if a
proper check should be put in place to prefer the `StrFormatByteSizeA` function
if the size argument is not > 4GiB.

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.



More information about the wine-bugs mailing list