In my application (ATMega1284p, Atmel Studio) I have functions I call to wrap "malloc" and "free" so that I can turn on some memory verification when needed to detect stack/heap collisions, buffer overrun, etc.
This has all worked well in the past but I recently started using some stl library functions that call malloc and free themselves which bypasses my wrapper functions causing the verification functions to fail.
Even though I have access to the malloc source I don't want to modify it if at all possible.
Using linker commands, etc. is it possible to have the linker direct all "malloc" references to "mymalloc" except for the references from "mymalloc" itself? (i.e.: allow "mymalloc" to intercept all calls to "malloc" while still allowing "mymalloc" to call the library "malloc")
Thanks in advance ...