Module: wine Branch: master Commit: fca468beb45ef313bd7c8184379f098bde705f52 URL: https://gitlab.winehq.org/wine/wine/-/commit/fca468beb45ef313bd7c8184379f098...
Author: Nikolay Sivov nsivov@codeweavers.com Date: Tue Nov 22 12:16:46 2022 +0300
comctl32/updown: Use CRT allocation functions.
Signed-off-by: Nikolay Sivov nsivov@codeweavers.com
---
dlls/comctl32/updown.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-)
diff --git a/dlls/comctl32/updown.c b/dlls/comctl32/updown.c index 1d00db275f2..f2befd9d448 100644 --- a/dlls/comctl32/updown.c +++ b/dlls/comctl32/updown.c @@ -33,7 +33,6 @@ #include "comctl32.h" #include "uxtheme.h" #include "vssym32.h" -#include "wine/heap.h" #include "wine/debug.h"
WINE_DEFAULT_DEBUG_CHANNEL(updown); @@ -902,7 +901,7 @@ static LRESULT WINAPI UpDownWindowProc(HWND hwnd, UINT message, WPARAM wParam, L { CREATESTRUCTW *pcs = (CREATESTRUCTW*)lParam;
- infoPtr = heap_alloc_zero(sizeof(*infoPtr)); + infoPtr = calloc(1, sizeof(*infoPtr)); SetWindowLongPtrW (hwnd, 0, (DWORD_PTR)infoPtr);
/* initialize the info struct */ @@ -935,9 +934,9 @@ static LRESULT WINAPI UpDownWindowProc(HWND hwnd, UINT message, WPARAM wParam, L break;
case WM_DESTROY: - heap_free (infoPtr->AccelVect); + free (infoPtr->AccelVect); UPDOWN_ResetSubclass (infoPtr); - heap_free (infoPtr); + free (infoPtr); SetWindowLongPtrW (hwnd, 0, 0); theme = GetWindowTheme (hwnd); CloseThemeData (theme); @@ -1060,12 +1059,12 @@ static LRESULT WINAPI UpDownWindowProc(HWND hwnd, UINT message, WPARAM wParam, L TRACE("UDM_SETACCEL\n");
if(infoPtr->AccelVect) { - heap_free (infoPtr->AccelVect); + free (infoPtr->AccelVect); infoPtr->AccelCount = 0; infoPtr->AccelVect = 0; } if(wParam==0) return TRUE; - infoPtr->AccelVect = heap_alloc(wParam*sizeof(UDACCEL)); + infoPtr->AccelVect = malloc(wParam*sizeof(UDACCEL)); if(!infoPtr->AccelVect) return FALSE; memcpy(infoPtr->AccelVect, (void*)lParam, wParam*sizeof(UDACCEL)); infoPtr->AccelCount = wParam;