Nikolay Sivov : comctl32/ipaddress: Use the global HeapAlloc() helpers.

Alexandre Julliard julliard at winehq.org
Fri Feb 9 14:51:44 CST 2018


Module: wine
Branch: master
Commit: bd4193ef9f0c08ecfa51a7d3e0740ff1eef7011d
URL:    https://source.winehq.org/git/wine.git/?a=commit;h=bd4193ef9f0c08ecfa51a7d3e0740ff1eef7011d

Author: Nikolay Sivov <nsivov at codeweavers.com>
Date:   Fri Feb  9 09:41:25 2018 +0300

comctl32/ipaddress: Use the global HeapAlloc() helpers.

Signed-off-by: Nikolay Sivov <nsivov at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/comctl32/ipaddress.c | 5 +++--
 1 file changed, 3 insertions(+), 2 deletions(-)

diff --git a/dlls/comctl32/ipaddress.c b/dlls/comctl32/ipaddress.c
index 98e7259..6c1edf9 100644
--- a/dlls/comctl32/ipaddress.c
+++ b/dlls/comctl32/ipaddress.c
@@ -50,6 +50,7 @@
 #include "vssym32.h"
 #include "wine/unicode.h"
 #include "wine/debug.h"
+#include "wine/heap.h"
 
 WINE_DEFAULT_DEBUG_CHANNEL(ipaddress);
 
@@ -228,7 +229,7 @@ static LRESULT IPADDRESS_Create (HWND hwnd, const CREATESTRUCTA *lpCreate)
     SetWindowLongW (hwnd, GWL_STYLE,
 		    GetWindowLongW(hwnd, GWL_STYLE) & ~WS_BORDER);
 
-    infoPtr = Alloc (sizeof(IPADDRESS_INFO));
+    infoPtr = heap_alloc_zero (sizeof(*infoPtr));
     if (!infoPtr) return -1;
     SetWindowLongPtrW (hwnd, 0, (DWORD_PTR)infoPtr);
 
@@ -287,7 +288,7 @@ static LRESULT IPADDRESS_Destroy (IPADDRESS_INFO *infoPtr)
     }
 
     SetWindowLongPtrW (infoPtr->Self, 0, 0);
-    Free (infoPtr);
+    heap_free (infoPtr);
     return 0;
 }
 




More information about the wine-cvs mailing list