From 1f4f9931b9d0a81b1446155babc4d8fe8d484a78 Mon Sep 17 00:00:00 2001 From: Jacob Hageman Date: Thu, 16 Sep 2021 18:06:16 +0000 Subject: [PATCH] Fix #1955, Add static local to function test so data section is nonzero --- modules/cfe_testcase/src/cfe_test.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/modules/cfe_testcase/src/cfe_test.c b/modules/cfe_testcase/src/cfe_test.c index cfc031ee4..a5ae1b5c0 100644 --- a/modules/cfe_testcase/src/cfe_test.c +++ b/modules/cfe_testcase/src/cfe_test.c @@ -41,6 +41,9 @@ CFE_FT_Global_t CFE_FT_Global; */ void CFE_TestMain(void) { + /* Static local so data section is not zero when checking app info */ + static char TestName[] = "CFE API"; + /* Constant Table information used by all table tests */ CFE_FT_Global.TblName = "TestTable"; CFE_FT_Global.RegisteredTblName = "CFE_TEST_APP.TestTable"; @@ -52,7 +55,7 @@ void CFE_TestMain(void) * Note this also waits for the appropriate overall system * state and gets ownership of the UtAssert subsystem */ - CFE_Assert_RegisterTest("CFE API"); + CFE_Assert_RegisterTest(TestName); CFE_Assert_OpenLogFile(CFE_ASSERT_LOG_FILE_NAME); /*