[Bug 15336] New: DirectInputCreate(): hInst is ignored; NULL value doesn't result in an error.

wine-bugs at winehq.org wine-bugs at winehq.org
Fri Sep 19 18:06:14 CDT 2008


http://bugs.winehq.org/show_bug.cgi?id=15336

           Summary: DirectInputCreate(): hInst is ignored; NULL value
                    doesn't result in an error.
           Product: Wine
           Version: 1.1.5
          Platform: PC
        OS/Version: Linux
            Status: UNCONFIRMED
          Severity: enhancement
          Priority: P2
         Component: directx-dinput
        AssignedTo: wine-bugs at winehq.org
        ReportedBy: gerbilsoft at verizon.net


While porting an application from Linux to Win32, I noticed a bug in Wine's
implementation of DirectInputCreate(). Specifically, Wine allows a NULL value
for hInst, whereas on Windows, specifying a NULL hInst results in error
0x80070057 ("The parameter is incorrect.")

Code:

HRESULT rval;
LPDIRECTINPUT lpDI;
HINSTANCE ghInstance = NULL;

rval = DirectInputCreate(hInst, 0x0500, &lpDI, NULL);

Expected Result: rval should contain 0x80070057 and lpDI should remain
uninitialized.

Actual Result: rval contains 0 and lpDI is initialized.


-- 
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
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