Commit 8990cf09 authored by Marcus Meissner's avatar Marcus Meissner Committed by Alexandre Julliard

dinput: GetKeyNameW takes chars not bytes (Coverity).

parent 5f85b7c8
......@@ -439,7 +439,7 @@ static HRESULT WINAPI SysKeyboardWImpl_GetObjectInfo(LPDIRECTINPUTDEVICE8W iface
scan = DIDFT_GETINSTANCE(pdidoi->dwType);
if (scan == DIK_PAUSE || scan == DIK_NUMLOCK) scan ^= 0x80;
if (!GetKeyNameTextW((scan & 0x80) << 17 | (scan & 0x7f) << 16,
pdidoi->tszName, sizeof(pdidoi->tszName)))
pdidoi->tszName, sizeof(pdidoi->tszName)/sizeof(pdidoi->tszName[0])))
return DIERR_OBJECTNOTFOUND;
_dump_OBJECTINSTANCEW(pdidoi);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment