You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The macro ulTaskNotifyTakeIndexed was introduced with FreeRTOS 10.4.0. The implementation of the macro had a mismatch between the named macro parameters and the use of these parameters in the macro as follows:
As this macro was only introduced in V10.4.0 and the failure is at compile time we consider the potential risk from this bug to be very limited.
Use the new macro ulTaskNotifyTakeIndexed as described in the forum post and you will observe a compilation error.
Additional context
The test code for this macro unfortunately had a local variable named uxIndexToNotify which masked the error during testing. The test was using this variable to pass the value into the macro which resulted in correct behavior because the variable name in the test was an exact match to the variable name incorrectly used in the macro implementation.
cobusve
changed the title
Mismatch of parameters in macro ulTaskNotifyTakeIndexed
Mismatch of parameters in macro ulTaskNotifyTakeIndexed causes compilation error
Sep 17, 2020
Describe the bug
This issue was first reported on the FreeRTOS forums here https://forums.freertos.org/t/task-h-error-uxindextonotify-undeclared/10689
The macro ulTaskNotifyTakeIndexed was introduced with FreeRTOS 10.4.0. The implementation of the macro had a mismatch between the named macro parameters and the use of these parameters in the macro as follows:
As this macro was only introduced in V10.4.0 and the failure is at compile time we consider the potential risk from this bug to be very limited.
The offending code is shown here
To Reproduce
Additional context
The test code for this macro unfortunately had a local variable named uxIndexToNotify which masked the error during testing. The test was using this variable to pass the value into the macro which resulted in correct behavior because the variable name in the test was an exact match to the variable name incorrectly used in the macro implementation.
See this location for the exact code
https://github.com/FreeRTOS/FreeRTOS/blob/89d475e9b112d7b52c3d16aeff97e1e8e6b95316/FreeRTOS/Demo/Common/Minimal/TaskNotifyArray.c#L954
The text was updated successfully, but these errors were encountered: