shell32: Add missing multiply by sizeof(WCHAR)l
This commit is contained in:
parent
93fb9d10f5
commit
f921fa544a
|
@ -636,7 +636,7 @@ static BOOL BrsFolder_OnSetSelectionA(browse_info *info, LPVOID selection, BOOL
|
||||||
return BrsFolder_OnSetSelectionW(info, selection, is_str);
|
return BrsFolder_OnSetSelectionW(info, selection, is_str);
|
||||||
|
|
||||||
if ((length = MultiByteToWideChar(CP_ACP, 0, (LPCSTR)selection, -1, NULL, 0)) &&
|
if ((length = MultiByteToWideChar(CP_ACP, 0, (LPCSTR)selection, -1, NULL, 0)) &&
|
||||||
(selectionW = HeapAlloc(GetProcessHeap(), 0, length)) &&
|
(selectionW = HeapAlloc(GetProcessHeap(), 0, length * sizeof(WCHAR))) &&
|
||||||
MultiByteToWideChar(CP_ACP, 0, (LPCSTR)selection, -1, selectionW, length))
|
MultiByteToWideChar(CP_ACP, 0, (LPCSTR)selection, -1, selectionW, length))
|
||||||
{
|
{
|
||||||
result = BrsFolder_OnSetSelectionW(info, selectionW, is_str);
|
result = BrsFolder_OnSetSelectionW(info, selectionW, is_str);
|
||||||
|
|
Loading…
Reference in New Issue