2 * COPYRIGHT: See COPYING in the top level directory
3 * PROJECT: ReactOS system libraries
4 * FILE: lib/crtdll/stdlib/malloc.c
5 * PURPOSE: stdc memory allocation functions
9 /* INCLUDES ******************************************************************/
14 /* FUNCTIONS *****************************************************************/
16 void* malloc(size_t size
)
18 return(HeapAlloc(GetProcessHeap(), 0, size
));
23 HeapFree(GetProcessHeap(), 0, ptr
);
26 void* calloc(size_t nmemb
, size_t size
)
28 return(HeapAlloc(GetProcessHeap(), HEAP_ZERO_MEMORY
, nmemb
*size
));
31 void* realloc(void* ptr
, size_t size
)
33 return(HeapReAlloc(GetProcessHeap(), 0, ptr
, size
));