mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-08-20 18:18:32 -04:00
Remove empty expression statement compiler warning (#692)
* Add do while( 0 ) loop for empty expression statement compiler warning
This commit is contained in:
parent
1c5eca348f
commit
d0a490e491
6 changed files with 28 additions and 26 deletions
|
@ -95,13 +95,13 @@ typedef QueueHandle_t SemaphoreHandle_t;
|
|||
*/
|
||||
#if ( configSUPPORT_DYNAMIC_ALLOCATION == 1 )
|
||||
#define vSemaphoreCreateBinary( xSemaphore ) \
|
||||
{ \
|
||||
do { \
|
||||
( xSemaphore ) = xQueueGenericCreate( ( UBaseType_t ) 1, semSEMAPHORE_QUEUE_ITEM_LENGTH, queueQUEUE_TYPE_BINARY_SEMAPHORE ); \
|
||||
if( ( xSemaphore ) != NULL ) \
|
||||
{ \
|
||||
( void ) xSemaphoreGive( ( xSemaphore ) ); \
|
||||
} \
|
||||
}
|
||||
} while( 0 )
|
||||
#endif
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue