crypt32: Use CRT allocation functions.

Signed-off-by: Hans Leidekker <hans@codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
Hans Leidekker 2022-03-30 11:47:46 +02:00 committed by Alexandre Julliard
parent 1fb28509f7
commit 8516a9e931
1 changed files with 4 additions and 3 deletions

View File

@ -18,6 +18,7 @@
*/ */
#include <stdarg.h> #include <stdarg.h>
#include <stdlib.h>
#include <stdio.h> #include <stdio.h>
#include "windef.h" #include "windef.h"
@ -136,17 +137,17 @@ HLRUCACHE WINAPI I_CryptFreeLruCache(HLRUCACHE h, DWORD unk0, DWORD unk1)
LPVOID WINAPI CryptMemAlloc(ULONG cbSize) LPVOID WINAPI CryptMemAlloc(ULONG cbSize)
{ {
return HeapAlloc(GetProcessHeap(), 0, cbSize); return malloc(cbSize);
} }
LPVOID WINAPI CryptMemRealloc(LPVOID pv, ULONG cbSize) LPVOID WINAPI CryptMemRealloc(LPVOID pv, ULONG cbSize)
{ {
return HeapReAlloc(GetProcessHeap(), 0, pv, cbSize); return realloc(pv, cbSize);
} }
VOID WINAPI CryptMemFree(LPVOID pv) VOID WINAPI CryptMemFree(LPVOID pv)
{ {
HeapFree(GetProcessHeap(), 0, pv); free(pv);
} }
DWORD WINAPI I_CryptAllocTls(void) DWORD WINAPI I_CryptAllocTls(void)