mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-09-16 11:07:44 -04:00
Fix add overflow check on recursive mutex counter
This commit is contained in:
parent
3fd7f174db
commit
ee2ee4dc7c
1 changed files with 4 additions and 0 deletions
4
queue.c
4
queue.c
|
@ -833,6 +833,10 @@ static void prvInitialiseNewQueue( const UBaseType_t uxQueueLength,
|
||||||
if( pxMutex->u.xSemaphore.xMutexHolder == xTaskGetCurrentTaskHandle() )
|
if( pxMutex->u.xSemaphore.xMutexHolder == xTaskGetCurrentTaskHandle() )
|
||||||
{
|
{
|
||||||
( pxMutex->u.xSemaphore.uxRecursiveCallCount )++;
|
( pxMutex->u.xSemaphore.uxRecursiveCallCount )++;
|
||||||
|
|
||||||
|
/* check if an overflow occurred */
|
||||||
|
configASSERT( pxMutex->u.xSemaphore.uxRecursiveCallCount );
|
||||||
|
|
||||||
xReturn = pdPASS;
|
xReturn = pdPASS;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue