my_malloc malloc, free, realloc, calloc from scratch You may try LD_PRELOAD=./libmy_malloc.so some-program