Francois Gouget : dnsapi: Add __WINE_ALLOC_SIZE attributes to heap_xxx() functions.

Alexandre Julliard julliard at winehq.org
Mon Feb 20 15:03:43 CST 2017


Module: wine
Branch: master
Commit: 773cfc2a88812cb9c90794821cde6998672bbc88
URL:    http://source.winehq.org/git/wine.git/?a=commit;h=773cfc2a88812cb9c90794821cde6998672bbc88

Author: Francois Gouget <fgouget at free.fr>
Date:   Sat Feb 18 11:22:19 2017 +0100

dnsapi: Add __WINE_ALLOC_SIZE attributes to heap_xxx() functions.

And standardize their type names.

Signed-off-by: Francois Gouget <fgouget at free.fr>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>

---

 dlls/dnsapi/dnsapi.h | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

diff --git a/dlls/dnsapi/dnsapi.h b/dlls/dnsapi/dnsapi.h
index e94b26b..8a02521 100644
--- a/dlls/dnsapi/dnsapi.h
+++ b/dlls/dnsapi/dnsapi.h
@@ -22,19 +22,19 @@
 # error You must include config.h to use this header
 #endif
 
-static inline void *heap_alloc( SIZE_T size )
+static inline void* __WINE_ALLOC_SIZE(1) heap_alloc(size_t size)
 {
-    return HeapAlloc( GetProcessHeap(), 0, size );
+    return HeapAlloc(GetProcessHeap(), 0, size);
 }
 
-static inline void *heap_alloc_zero( SIZE_T size )
+static inline void* __WINE_ALLOC_SIZE(1) heap_alloc_zero(size_t size)
 {
-    return HeapAlloc( GetProcessHeap(), HEAP_ZERO_MEMORY, size );
+    return HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, size);
 }
 
-static inline BOOL heap_free( LPVOID mem )
+static inline BOOL heap_free(void *mem)
 {
-    return HeapFree( GetProcessHeap(), 0, mem );
+    return HeapFree(GetProcessHeap(), 0, mem);
 }
 
 static inline LPSTR dns_strdup_a( LPCSTR src )




More information about the wine-cvs mailing list