dinput: Fix character count passed to GetKeyNameTextW in SysKeyboardWImpl_GetObjectInfo.

This commit is contained in:
Rob Shearman 2008-02-25 09:01:49 +00:00 committed by Alexandre Julliard
parent e7173dfa4e
commit fe75a8c616

View File

@ -361,7 +361,8 @@ static HRESULT WINAPI SysKeyboardWImpl_GetObjectInfo(LPDIRECTINPUTDEVICE8W iface
if (!GetKeyNameTextW((DIDFT_GETINSTANCE(pdidoi->dwType) & 0x80) << 17 |
(DIDFT_GETINSTANCE(pdidoi->dwType) & 0x7f) << 16,
pdidoi->tszName, sizeof(pdidoi->tszName)))
pdidoi->tszName,
sizeof(pdidoi->tszName)/sizeof(pdidoi->tszName[0])))
return DIERR_OBJECTNOTFOUND;
_dump_OBJECTINSTANCEW(pdidoi);