mirror of
https://github.com/FreeRTOS/FreeRTOS-Kernel.git
synced 2025-10-14 00:37:44 -04:00
Fix optimization bug and cleanup (#1363)
- Compiling Demo/Common/Minimal/TimerDemo.c with "gcc -flto" breaks the tests, so add "volatile" modifier to "ucOneShotTimerCounter" to fix this. - In Demo/FreeRTOS_Plus_TCP_Echo_Qemu_mps2/main_networking.c print the network configuration even more visible. - In MessageBufferDemo.c and Demo/Posix_GCC/main_full.c fix compiler warnings from "gcc -Wwrite-strings" by adding a const modifier. Signed-off-by: Florian La Roche <Florian.LaRoche@gmail.com>
This commit is contained in:
parent
722d17b13a
commit
e0aa5eac74
4 changed files with 6 additions and 4 deletions
|
@ -108,7 +108,7 @@ static uint8_t ucIsStopNeededInTimerZeroCallback = ( uint8_t ) pdFALSE;
|
|||
/* The one-shot timer is configured to use a callback function that increments
|
||||
* ucOneShotTimerCounter each time it gets called. */
|
||||
static TimerHandle_t xOneShotTimer = NULL;
|
||||
static uint8_t ucOneShotTimerCounter = ( uint8_t ) 0;
|
||||
static volatile uint8_t ucOneShotTimerCounter = ( uint8_t ) 0;
|
||||
|
||||
/* The ISR reload timer is controlled from the tick hook to exercise the timer
|
||||
* API functions that can be used from an ISR. It is configured to increment
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue