Page 1 of 1

**Freeing NULL pointers

Posted: Tue Aug 18, 2015 1:07 pm
by JoVM
Why chHeapFree() doesn't support freeing NULL pointers?

Code: Select all

chDbgCheck(p != NULL);


It is heavily supported in mbed TLS and my code has runtime failures. Is a wrapper required or else?

Re: **Freeing NULL pointers

Posted: Tue Aug 18, 2015 2:22 pm
by Giovanni
It is considered an error, it has no meaning anyway. You may create a wrapper function if you need that.

Giovanni