Signed-off-by: Rémi Bernon rbernon@codeweavers.com --- dlls/dinput/device.c | 1 + dlls/dinput8/tests/hid.c | 1 - 2 files changed, 1 insertion(+), 1 deletion(-)
diff --git a/dlls/dinput/device.c b/dlls/dinput/device.c index 17eaff69d50..2a3ed391919 100644 --- a/dlls/dinput/device.c +++ b/dlls/dinput/device.c @@ -1094,6 +1094,7 @@ HRESULT WINAPI IDirectInputDevice2WImpl_SetDataFormat(LPDIRECTINPUTDEVICE8W ifac _dump_DIDATAFORMAT(df);
if (df->dwSize != sizeof(DIDATAFORMAT)) return DIERR_INVALIDPARAM; + if (df->dwObjSize != sizeof(DIOBJECTDATAFORMAT)) return DIERR_INVALIDPARAM; if (This->acquired) return DIERR_ACQUIRED;
EnterCriticalSection(&This->crit); diff --git a/dlls/dinput8/tests/hid.c b/dlls/dinput8/tests/hid.c index 371edc99251..e017e048a30 100644 --- a/dlls/dinput8/tests/hid.c +++ b/dlls/dinput8/tests/hid.c @@ -4015,7 +4015,6 @@ static void test_simple_joystick(void) ok( hr == DIERR_INVALIDPARAM, "IDirectInputDevice8_SetDataFormat returned: %#x\n", hr ); dataformat.dwSize = sizeof(DIDATAFORMAT); hr = IDirectInputDevice8_SetDataFormat( device, &dataformat ); - todo_wine ok( hr == DIERR_INVALIDPARAM, "IDirectInputDevice8_SetDataFormat returned: %#x\n", hr ); dataformat.dwObjSize = sizeof(DIOBJECTDATAFORMAT); hr = IDirectInputDevice8_SetDataFormat( device, &dataformat );