Fix datatype of queue item length macros (#1286)

The uxItemSize parameter in xQueueGenericCreate and
xQueueGeneenericCreateStatic APIs expects a UBaseType_t type.
Previously, the semSEMAPHORE_QUEUE_ITEM_LENGTH macro incorrectly cast
the value to uint8_t, causing type mismatch warnings. This change
resolves the issue by properly casting the value to UBaseType_t.

This issue was reported here: https://github.com/FreeRTOS/FreeRTOS-Kernel/issues/1285.

Signed-off-by: Gaurav Aggarwal <aggarg@amazon.com>
This commit is contained in:
Gaurav-Aggarwal-AWS 2025-06-30 18:11:30 +05:30 committed by GitHub
parent a882b10526
commit 7225fbcbb9
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -37,8 +37,8 @@
typedef QueueHandle_t SemaphoreHandle_t;
#define semBINARY_SEMAPHORE_QUEUE_LENGTH ( ( uint8_t ) 1U )
#define semSEMAPHORE_QUEUE_ITEM_LENGTH ( ( uint8_t ) 0U )
#define semBINARY_SEMAPHORE_QUEUE_LENGTH ( ( UBaseType_t ) 1U )
#define semSEMAPHORE_QUEUE_ITEM_LENGTH ( ( UBaseType_t ) 0U )
#define semGIVE_BLOCK_TIME ( ( TickType_t ) 0U )