mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-08-19 17:48:33 -04:00
Fix small bugs in Kernel (#998)
* Fix small bugs * Cast sizeof to BaseType_t * Test removing assert to fix UT * Revert change to tasks.c Since configIDLE_TASK_NAME must be defined as a string according to the documentation, the macro will always be NULL terminated. Which means that the check `if( cIdleName[ xIdleTaskNameIndex ] == ( char ) 0x00 )` will catch the end of string. * Update coverity config; Add coverity version; Update pvPortMalloc declaration to match the definitions. * Add port files to sed command * Remove warnings about unused parameters in port code --------- Co-authored-by: Rahul Kar <118818625+kar-rahul-aws@users.noreply.github.com>
This commit is contained in:
parent
1a500f1a74
commit
2fcb0f48b1
7 changed files with 68 additions and 69 deletions
|
@ -2,8 +2,9 @@ cmake_minimum_required(VERSION 3.15)
|
|||
|
||||
project(coverity)
|
||||
|
||||
set(FREERTOS_KERNEL_PATH "../../")
|
||||
FILE(GLOB FREERTOS_KERNEL_SOURCE ${FREERTOS_KERNEL_PATH}*.c)
|
||||
set(FREERTOS_KERNEL_PATH "../..")
|
||||
FILE(GLOB FREERTOS_KERNEL_SOURCE ${FREERTOS_KERNEL_PATH}/*.c)
|
||||
FILE(GLOB FREERTOS_PORT_CODE ${FREERTOS_KERNEL_PATH}/portable/template/*.c)
|
||||
|
||||
# Coverity incorrectly infers the type of pdTRUE and pdFALSE as boolean because
|
||||
# of their names. This generates multiple false positive warnings about type
|
||||
|
@ -12,8 +13,8 @@ FILE(GLOB FREERTOS_KERNEL_SOURCE ${FREERTOS_KERNEL_PATH}*.c)
|
|||
# fixes the issue of incorrectly inferring the type of pdTRUE and pdFALSE as
|
||||
# boolean.
|
||||
add_custom_target(fix_source ALL
|
||||
COMMAND sed -i -b -e 's/pdFALSE/pdFAIL/g' -e 's/pdTRUE/pdPASS/g' ${FREERTOS_KERNEL_SOURCE}
|
||||
DEPENDS ${FREERTOS_KERNEL_SOURCE})
|
||||
COMMAND sed -i -b -e 's/pdFALSE/pdFAIL/g' -e 's/pdTRUE/pdPASS/g' ${FREERTOS_KERNEL_SOURCE} ${FREERTOS_PORT_CODE}
|
||||
DEPENDS ${FREERTOS_KERNEL_SOURCE} ${FREERTOS_PORT_CODE})
|
||||
|
||||
# Add the freertos_config for FreeRTOS-Kernel.
|
||||
add_library(freertos_config INTERFACE)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue