I would like to replace the default malloc at link time to use a custom malloc. But when I try to redefine malloc in my program, I get this error:
MSVCRT.lib
What about defining malloc=_custom_malloc in the project makefile. Than adding a file such as:
my_memory.c #undef malloc #undef calloc ... void *_custom_malloc(int size) { return jmalloc(size); } void *_custom_calloc(int size) { return jcalloc(size); } ...