From 754b9eed2fc5b54b94a8260b5529225edeea1b1e Mon Sep 17 00:00:00 2001 From: Patrick Boettcher Date: Tue, 7 Aug 2018 16:02:13 +0200 Subject: [PATCH 1/2] Death-test: sometimes 6 extra-tasks are created This fixes the test-suite with FreeRTOS 10. --- Demo/Common/Full/death.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Demo/Common/Full/death.c b/Demo/Common/Full/death.c index a7bb7d7..fd703ba 100644 --- a/Demo/Common/Full/death.c +++ b/Demo/Common/Full/death.c @@ -77,7 +77,7 @@ static volatile short sCreationCount = 0; /* Used to store the number of tasks that were originally running so the creator task can tell if any of the suicidal tasks have failed to die. */ static volatile unsigned portBASE_TYPE uxTasksRunningAtStart = 0; -static const unsigned portBASE_TYPE uxMaxNumberOfExtraTasksRunning = 5; +static const unsigned portBASE_TYPE uxMaxNumberOfExtraTasksRunning = 6; /* Used to store a handle to the tasks that should be killed by a suicidal task, before it kills itself. */ From 58b732c29a9820a80d325630772d4bc234ca02b8 Mon Sep 17 00:00:00 2001 From: Patrick Boettcher Date: Tue, 7 Aug 2018 16:04:26 +0200 Subject: [PATCH 2/2] Full/death-test: sLastCreationCount was never set to current-value The check can only fail if nothing is ever created, but not if it stops right in the middle. --- Demo/Common/Full/death.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Demo/Common/Full/death.c b/Demo/Common/Full/death.c index fd703ba..29f1ef8 100644 --- a/Demo/Common/Full/death.c +++ b/Demo/Common/Full/death.c @@ -181,7 +181,11 @@ unsigned portBASE_TYPE uxTasksRunningNow; { sReturn = pdFALSE; } - + else + { + sLastCreationCount = sCreationCount; + } + uxTasksRunningNow = uxTaskGetNumberOfTasks(); if( uxTasksRunningNow < uxTasksRunningAtStart )