ole32: Fix string buffer size.
Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
cab617bbab
commit
a697aa21f3
|
@ -554,7 +554,7 @@ static HRESULT PropertyStorage_StringCopy(LPCSTR src, UINT srcCP, LPSTR *dst, UI
|
||||||
len = (lstrlenW((LPCWSTR)src) + 1) * sizeof(WCHAR);
|
len = (lstrlenW((LPCWSTR)src) + 1) * sizeof(WCHAR);
|
||||||
else
|
else
|
||||||
len = strlen(src) + 1;
|
len = strlen(src) + 1;
|
||||||
*dst = CoTaskMemAlloc(len * sizeof(WCHAR));
|
*dst = CoTaskMemAlloc(len);
|
||||||
if (!*dst)
|
if (!*dst)
|
||||||
hr = STG_E_INSUFFICIENTMEMORY;
|
hr = STG_E_INSUFFICIENTMEMORY;
|
||||||
else
|
else
|
||||||
|
|
Loading…
Reference in New Issue