From fbdc08dcebaecf5fe491dcdee41e37823a2df8ec Mon Sep 17 00:00:00 2001 From: Brock Mammen Date: Tue, 27 Aug 2019 08:17:11 -0500 Subject: [PATCH] [SHELLFIND] Use CoTaskMemAlloc instead of SHAlloc --- dll/win32/browseui/shellfind/CSearchBar.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/dll/win32/browseui/shellfind/CSearchBar.cpp b/dll/win32/browseui/shellfind/CSearchBar.cpp index 4463669ad2d..3c497030cb9 100644 --- a/dll/win32/browseui/shellfind/CSearchBar.cpp +++ b/dll/win32/browseui/shellfind/CSearchBar.cpp @@ -149,7 +149,7 @@ HRESULT CSearchBar::GetSearchResultsFolder(IShellBrowser **ppShellBrowser, HWND LRESULT CSearchBar::OnSearchButtonClicked(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled) { - CComHeapPtr pSearchStart((SearchStart *)SHAlloc(sizeof(SearchStart))); + CComHeapPtr pSearchStart(static_cast(CoTaskMemAlloc(sizeof(SearchStart)))); GetDlgItemText(IDC_SEARCH_FILENAME, pSearchStart->szFileName, _countof(pSearchStart->szFileName)); GetDlgItemText(IDC_SEARCH_QUERY, pSearchStart->szQuery, _countof(pSearchStart->szQuery)); if (!GetAddressEditBoxPath(pSearchStart->szPath)) -- 2.17.1