shlwapi: RegQueryValueExW() wants bytes, not chars.

Signed-off-by: Serge Gautherie <winehq-git_serge_180711@gautherie.fr>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Serge Gautherie 2020-05-28 04:30:53 +02:00 committed by Alexandre Julliard
parent a359e02666
commit 0662da18b8
1 changed files with 1 additions and 1 deletions

View File

@ -3372,7 +3372,7 @@ HRESULT WINAPI CLSIDFromStringWrap(LPCWSTR idstr, CLSID *id)
*/
HRESULT WINAPI SHLoadRegUIStringW(HKEY hkey, LPCWSTR value, LPWSTR buf, DWORD size)
{
DWORD type, sz = size;
DWORD type, sz = size * sizeof(WCHAR);
if(RegQueryValueExW(hkey, value, NULL, &type, (LPBYTE)buf, &sz) != ERROR_SUCCESS)
return E_FAIL;