[SHELLFIND] Use CoTaskMemAlloc instead of SHAlloc

This commit is contained in:
Brock Mammen 2019-08-27 08:17:11 -05:00 committed by Giannis Adamopoulos
parent d0171027e0
commit fbdc08dceb

View file

@ -149,7 +149,7 @@ HRESULT CSearchBar::GetSearchResultsFolder(IShellBrowser **ppShellBrowser, HWND
LRESULT CSearchBar::OnSearchButtonClicked(WORD wNotifyCode, WORD wID, HWND hWndCtl, BOOL& bHandled)
{
CComHeapPtr<SearchStart> pSearchStart((SearchStart *)SHAlloc(sizeof(SearchStart)));
CComHeapPtr<SearchStart> pSearchStart(static_cast<SearchStart *>(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))