comctl32/hotkey: Use HeapAlloc() wrappers.

Signed-off-by: Nikolay Sivov <nsivov@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Nikolay Sivov 2018-02-02 08:39:41 +03:00 committed by Alexandre Julliard
parent ff1cd359f7
commit fee6ec8cf3

View File

@ -38,6 +38,7 @@
#include "commctrl.h" #include "commctrl.h"
#include "comctl32.h" #include "comctl32.h"
#include "wine/debug.h" #include "wine/debug.h"
#include "wine/heap.h"
WINE_DEFAULT_DEBUG_CHANNEL(hotkey); WINE_DEFAULT_DEBUG_CHANNEL(hotkey);
@ -241,7 +242,7 @@ HOTKEY_Destroy (HOTKEY_INFO *infoPtr)
{ {
/* free hotkey info data */ /* free hotkey info data */
SetWindowLongPtrW (infoPtr->hwndSelf, 0, 0); SetWindowLongPtrW (infoPtr->hwndSelf, 0, 0);
Free (infoPtr); heap_free (infoPtr);
return 0; return 0;
} }
@ -410,7 +411,7 @@ HOTKEY_NCCreate (HWND hwnd, const CREATESTRUCTW *lpcs)
dwExStyle | WS_EX_CLIENTEDGE); dwExStyle | WS_EX_CLIENTEDGE);
/* allocate memory for info structure */ /* allocate memory for info structure */
infoPtr = Alloc (sizeof(HOTKEY_INFO)); infoPtr = heap_alloc_zero (sizeof(*infoPtr));
SetWindowLongPtrW(hwnd, 0, (DWORD_PTR)infoPtr); SetWindowLongPtrW(hwnd, 0, (DWORD_PTR)infoPtr);
/* initialize info structure */ /* initialize info structure */