want to allocate and clean RAM statically. */\r
portCLEAN_UP_TCB( pxTCB );\r
\r
- /* Free up the memory allocated by the scheduler for the task. It is up to\r
- the task to free any memory allocated at the application level. */\r
+ /* Free up the memory allocated by the scheduler for the task. It is up\r
+ to the task to free any memory allocated at the application level. */\r
+ #if ( configUSE_NEWLIB_REENTRANT == 1 )\r
+ {\r
+ _reclaim_reent( &( pxTCB->xNewLib_reent ) );\r
+ }\r
+ #endif /* configUSE_NEWLIB_REENTRANT */\r
vPortFreeAligned( pxTCB->pxStack );\r
vPortFree( pxTCB );\r
}\r