From f921fa544aeb018286d49e58343f1c61ab4924fe Mon Sep 17 00:00:00 2001 From: James Hawkins Date: Fri, 23 Jun 2006 05:24:40 -0700 Subject: [PATCH] shell32: Add missing multiply by sizeof(WCHAR)l --- dlls/shell32/brsfolder.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dlls/shell32/brsfolder.c b/dlls/shell32/brsfolder.c index 88516a2bae0..2ef6b761d51 100644 --- a/dlls/shell32/brsfolder.c +++ b/dlls/shell32/brsfolder.c @@ -636,7 +636,7 @@ static BOOL BrsFolder_OnSetSelectionA(browse_info *info, LPVOID selection, BOOL return BrsFolder_OnSetSelectionW(info, selection, is_str); 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)) { result = BrsFolder_OnSetSelectionW(info, selectionW, is_str);