mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-06-05 20:09:05 -04:00
Modified uxTaskGetStackHighWaterMark() to take a parameter for the task to be checked, rather than just checking the stack of the calling task.
This commit is contained in:
parent
6e59817356
commit
47a7f0165b
|
@ -1858,9 +1858,12 @@ tskTCB *pxNewTCB;
|
||||||
|
|
||||||
#if ( INCLUDE_uxTaskGetStackHighWaterMark == 1 )
|
#if ( INCLUDE_uxTaskGetStackHighWaterMark == 1 )
|
||||||
|
|
||||||
unsigned portBASE_TYPE uxTaskGetStackHighWaterMark( void )
|
unsigned portBASE_TYPE uxTaskGetStackHighWaterMark( xTaskHandle xTask )
|
||||||
{
|
{
|
||||||
return usTaskCheckFreeStackSpace( ( unsigned portCHAR * ) pxCurrentTCB->pxStack );
|
tskTCB *pxTCB;
|
||||||
|
|
||||||
|
pxTCB = prvGetTCBFromHandle( xTask );
|
||||||
|
return usTaskCheckFreeStackSpace( ( unsigned portCHAR * ) pxTCB->pxStack );
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Reference in a new issue