Bug 15955 – dwExtraInfo in winuser.d is DWORD in some cases, should be ULONG_PTR

Status
RESOLVED
Resolution
DUPLICATE
Severity
normal
Priority
P1
Component
druntime
Product
D
Version
D2
Platform
x86_64
OS
Windows
Creation time
2016-04-25T17:19:00Z
Last change time
2016-04-29T00:28:27Z
Assigned to
nobody
Creator
kelethunter

Comments

Comment #0 by kelethunter — 2016-04-25T17:19:19Z
Hello, On 32-bit Windows, dwExtraInfo was a DWORD. But since the transition to x86_64, it has now been changed to a ULONG_PTR. The MSDN specifies that it should be a ULONG_PTR. In druntime/winuser.d, dwExtraInfo in most structs is a ULONG_PTR, but not always. For example, in MOUSEHOOKSTRUCT it is still a DWORD, which can cause inconsistencies (NULL cannot implicitly be used as a value, for example). To fix this issue: KBDLLHOOKSTRUCT MOUSEHOOKSTRUCT In both of these structs, dwExtraInfo needs to be a ULONG_PTR instead of a DWORD. I could be wrong with my assertion, but I'm only comparing the D Windows API to the MSDN to find these inconsistencies. Regards, Kelet
Comment #1 by jiki — 2016-04-29T00:28:27Z
I'll fix this and the others in issue 15959. *** This issue has been marked as a duplicate of issue 15959 ***