[Bug 42072] Dead Space (Steam) crashes on save with "divide by zero" error

WineHQ Bugzilla wine-bugs at winehq.org
Mon Dec 23 22:40:08 CST 2019


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

Zachary J <zakarjor at yahoo.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |zakarjor at yahoo.com

--- Comment #21 from Zachary J <zakarjor at yahoo.com> ---
I've encountered this issue and I always use symlink to My\ Documents (I keep
drive_c in a separate partition).

Debug log clearly shows Dead Space only gives 16 bytes for output, which is not
enough for normal unix pathnames:

003c:trace:volume:GetVolumePathNameW (L"c:\\users\\USERNAME\\My
Documents\\Electronic Arts\\Dead Space", 0x1346fcd8, 16)

I patched wine-4.21/dlls/kernel32/volume.c GetVolumePathNameW() by changing 2
lines so that in case last_pos+1>buflen, just revert to default drive letter or
something rather than failing:

L1808: if (status!=STATUS_SUCCESS || last_pos+1>buflen)
L1813: if (status!=STATUS_SUCCESS && filename[0]=='\\' && strncmpW(.)!=0)

This should at least retain the original logic for other cases.

-- 
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