Memory leaks in embedded systems can be risky and there are some tools to identify, track and analyze memory leaks in the embedded C & C++ programs.  The library functions of the standard C malloc() and free() help to allow memory blocks which are of arbitrary size to be allocated to an application for an arbitrary period of time.