directly use HeapAlloc/Free in midl_user_allocate and midl_user_free instead of the depreciated GlobalAlloc/Free functions

svn path=/trunk/; revision=14999
This commit is contained in:
Thomas Bluemel 2005-05-05 13:24:39 +00:00
parent cb363f4f7d
commit da6a50d93f
3 changed files with 6 additions and 6 deletions

View file

@ -948,12 +948,12 @@ UnlockServiceDatabase(SC_LOCK ScLock)
void __RPC_FAR * __RPC_USER midl_user_allocate(size_t len) void __RPC_FAR * __RPC_USER midl_user_allocate(size_t len)
{ {
return GlobalAlloc(GPTR,len); return HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, len);
} }
void __RPC_USER midl_user_free(void __RPC_FAR * ptr) void __RPC_USER midl_user_free(void __RPC_FAR * ptr)
{ {
GlobalFree(ptr); HeapFree(GetProcessHeap(), 0, ptr);
} }
/* EOF */ /* EOF */

View file

@ -69,14 +69,14 @@ PnpUnbindLocalBindingHandle(VOID)
void __RPC_FAR * __RPC_USER void __RPC_FAR * __RPC_USER
midl_user_allocate(size_t len) midl_user_allocate(size_t len)
{ {
return GlobalAlloc(GPTR, len); return HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, len);
} }
void __RPC_USER void __RPC_USER
midl_user_free(void __RPC_FAR * ptr) midl_user_free(void __RPC_FAR * ptr)
{ {
GlobalFree(ptr); HeapFree(GetProcessHeap(), 0, ptr);
} }
/* EOF */ /* EOF */

View file

@ -103,13 +103,13 @@ RpcServerThread(LPVOID lpParameter)
void __RPC_FAR * __RPC_USER midl_user_allocate(size_t len) void __RPC_FAR * __RPC_USER midl_user_allocate(size_t len)
{ {
return GlobalAlloc(GPTR, len); return HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY, len);
} }
void __RPC_USER midl_user_free(void __RPC_FAR * ptr) void __RPC_USER midl_user_free(void __RPC_FAR * ptr)
{ {
GlobalFree(ptr); HeapFree(GetProcessHeap(), 0, ptr);
} }