[Bug 47762] New: LoadStringA fails instead of returning const pointer to string if buffer length is zero
WineHQ Bugzilla
wine-bugs at winehq.org
Sat Sep 14 11:25:25 CDT 2019
https://bugs.winehq.org/show_bug.cgi?id=47762
Bug ID: 47762
Summary: LoadStringA fails instead of returning const pointer
to string if buffer length is zero
Product: Wine
Version: unspecified
Hardware: x86
OS: Linux
Status: UNCONFIRMED
Severity: normal
Priority: P2
Component: user32
Assignee: wine-bugs at winehq.org
Reporter: tsmx at tut.by
Distribution: ---
https://docs.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-loadstringa
According to MSDN doc, LoadStringA should be able to return const pointer
without using allocated buffer if the buffer size is set to zero.
Here we see that Wine just returns -1 in that case:
https://source.winehq.org/git/wine.git/blob/refs/heads/master:/dlls/user32/resource.c#l303
Since there is something that looks legit in the LoadStringW just above, it
shouldn't be too hard to fix, amirite?
--
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