From a7654a2c25346c3e3b33f9b787befda4f9223ee9 Mon Sep 17 00:00:00 2001 From: Avi Weiss Date: Thu, 7 Dec 2023 15:09:17 +1000 Subject: [PATCH] Fix #2478, Add missing `deafult`/`break` to `switch` statements --- .github/workflows/code-coverage.yml | 4 ++-- .github/workflows/codeql-build.yml | 2 +- .github/workflows/icbundle.yml | 2 +- docs/cFS_IdentifierNamingConvention.md | 2 +- modules/cfe_assert/src/cfe_assert_runner.c | 2 +- modules/cfe_testcase/src/cfe_test.c | 2 +- modules/cfe_testcase/src/cfe_test.h | 2 +- modules/cfe_testcase/src/es_behavior_test.c | 2 +- modules/cfe_testcase/src/sb_pipe_mang_test.c | 2 +- modules/cfe_testcase/tables/cfe_test_tbl.c | 2 +- .../default_cfe_core_api_interface_cfg.h | 2 +- .../core_private/ut-stubs/inc/ut_support.h | 2 +- .../core_private/ut-stubs/src/ut_support.c | 6 ++--- modules/es/fsw/src/cfe_es_erlog.c | 2 +- modules/es/ut-coverage/es_UT.c | 2 +- modules/evs/ut-coverage/evs_UT.c | 2 +- modules/fs/config/default_cfe_fs_filedef.h | 2 +- modules/msg/fsw/src/cfe_msg_ccsdspri.c | 2 ++ modules/sb/fsw/src/cfe_sb_api.c | 23 ++++++++++++++++++- modules/sb/fsw/src/cfe_sb_task.c | 4 ++++ modules/sb/ut-coverage/sb_UT.c | 8 +++---- modules/tbl/fsw/src/cfe_tbl_api.c | 1 + modules/tbl/ut-coverage/tbl_UT.c | 14 +++++------ 23 files changed, 60 insertions(+), 32 deletions(-) diff --git a/.github/workflows/code-coverage.yml b/.github/workflows/code-coverage.yml index 47465454c..a53ce4fc9 100644 --- a/.github/workflows/code-coverage.yml +++ b/.github/workflows/code-coverage.yml @@ -104,8 +104,8 @@ jobs: - name: Confirm Minimum Coverage run: | - missed_branches=50 - missed_lines=17 + missed_branches=47 + missed_lines=36 branch_nums=$(grep -A 3 "Overall coverage rate" lcov_out.txt | grep branches | grep -oP "[0-9]+[0-9]*") line_nums=$(grep -A 3 "Overall coverage rate" lcov_out.txt | grep lines | grep -oP "[0-9]+[0-9]*") diff --git a/.github/workflows/codeql-build.yml b/.github/workflows/codeql-build.yml index 1c86e725d..59d500c16 100644 --- a/.github/workflows/codeql-build.yml +++ b/.github/workflows/codeql-build.yml @@ -11,7 +11,7 @@ on: jobs: codeql: uses: nasa/cFS/.github/workflows/codeql-reusable.yml@main - with: + with: component-path: cfe make: make -j8 test: true diff --git a/.github/workflows/icbundle.yml b/.github/workflows/icbundle.yml index 460cff552..728890333 100644 --- a/.github/workflows/icbundle.yml +++ b/.github/workflows/icbundle.yml @@ -59,7 +59,7 @@ jobs: done changelog_entry="${changelog_entry}\n${see_entry}\n" sed -ir "s|# Changelog|$changelog_entry|" CHANGELOG.md - + buildnumber_entry=$'#define CFE_BUILD_NUMBER '${rev_num}$' /**< @brief Development: Number of development git commits since CFE_BUILD_BASELINE */' sed -ir "s|#define CFE_BUILD_NUMBER.*|$buildnumber_entry|" modules/core_api/fsw/inc/cfe_version.h - name: Commit and Push Updates to IC Branch diff --git a/docs/cFS_IdentifierNamingConvention.md b/docs/cFS_IdentifierNamingConvention.md index c64493bcb..c6cb47978 100644 --- a/docs/cFS_IdentifierNamingConvention.md +++ b/docs/cFS_IdentifierNamingConvention.md @@ -247,7 +247,7 @@ Common command/event descriptions include: | `LEN_ERR` | Incorrect Message Length | Error | | `CC_ERR` | Invalid Command Code Received | Error | | `NOOP_INF` | No-op Command Success | Informational | -| `INIT_INF` | Applicaiton Initialization Success | Informational | +| `INIT_INF` | Application Initialization Success | Informational | | `RESET_INF` | Reset Command Counters Command Success | Informational | # Appendix: Abbreviation Guide diff --git a/modules/cfe_assert/src/cfe_assert_runner.c b/modules/cfe_assert/src/cfe_assert_runner.c index 74a0b53a7..11474f965 100644 --- a/modules/cfe_assert/src/cfe_assert_runner.c +++ b/modules/cfe_assert/src/cfe_assert_runner.c @@ -138,7 +138,7 @@ bool CFE_Assert_Status_DeferredCheck(CFE_Status_t Status, UtAssert_CaseType_t Ca } else { - /* if condition was false add an exta marker so user does not necessarily need to decode the string */ + /* if condition was false add an extra marker so user does not necessarily need to decode the string */ ExtraTag = " [false]"; } diff --git a/modules/cfe_testcase/src/cfe_test.c b/modules/cfe_testcase/src/cfe_test.c index 388a289bf..3e160c0cd 100644 --- a/modules/cfe_testcase/src/cfe_test.c +++ b/modules/cfe_testcase/src/cfe_test.c @@ -58,7 +58,7 @@ void CFE_TestMain(void) * Register test cases in UtAssert */ ESApplicationControlTestSetup(); - ESBehaviorestSetup(); + ESBehaviorTestSetup(); ESCDSTestSetup(); ESCounterTestSetup(); ESErrorTestSetup(); diff --git a/modules/cfe_testcase/src/cfe_test.h b/modules/cfe_testcase/src/cfe_test.h index a7864c370..6104e041c 100644 --- a/modules/cfe_testcase/src/cfe_test.h +++ b/modules/cfe_testcase/src/cfe_test.h @@ -72,7 +72,7 @@ void TimeInRange(CFE_TIME_SysTime_t Start, CFE_TIME_SysTime_t Time, CFE_TIME_Sys void CFE_TestMain(void); void ESApplicationControlTestSetup(void); -void ESBehaviorestSetup(void); +void ESBehaviorTestSetup(void); void ESCDSTestSetup(void); void ESCounterTestSetup(void); void ESErrorTestSetup(void); diff --git a/modules/cfe_testcase/src/es_behavior_test.c b/modules/cfe_testcase/src/es_behavior_test.c index 0cef9db8e..1223a876e 100644 --- a/modules/cfe_testcase/src/es_behavior_test.c +++ b/modules/cfe_testcase/src/es_behavior_test.c @@ -82,7 +82,7 @@ void TestWaitBehavior(void) UtAssert_UINT32_EQ(CFE_TIME_Compare(TimePassed, TimeExpected), CFE_TIME_A_LT_B); } -void ESBehaviorestSetup(void) +void ESBehaviorTestSetup(void) { UtTest_Add(TestRunCounter, NULL, NULL, "Test Run Counter"); UtTest_Add(TestWaitBehavior, NULL, NULL, "Test Wait Behavior"); diff --git a/modules/cfe_testcase/src/sb_pipe_mang_test.c b/modules/cfe_testcase/src/sb_pipe_mang_test.c index 0fe7b5f2c..662225620 100644 --- a/modules/cfe_testcase/src/sb_pipe_mang_test.c +++ b/modules/cfe_testcase/src/sb_pipe_mang_test.c @@ -74,7 +74,7 @@ void TestPipeCreateMax(void) * Normally, this will return CFE_SUCCESS, until the max number of pipes is reached. * Confirm that the last creation attempt returned CFE_SB_MAX_PIPES_MET * - * NOTE: this also mimics the same format as UtAssert_INT32_EQ so that any post-procesing + * NOTE: this also mimics the same format as UtAssert_INT32_EQ so that any post-processing * test log analysis tools will see this call as well. */ if (CFE_Assert_STATUS_MAY_BE(CFE_SB_MAX_PIPES_MET)) diff --git a/modules/cfe_testcase/tables/cfe_test_tbl.c b/modules/cfe_testcase/tables/cfe_test_tbl.c index dd71344d7..1a24fec01 100644 --- a/modules/cfe_testcase/tables/cfe_test_tbl.c +++ b/modules/cfe_testcase/tables/cfe_test_tbl.c @@ -30,7 +30,7 @@ /* * The test table data should contain some identifiable numeric values, - * so any issues with paritial loading/byteswapping are morely likely + * so any issues with partial loading/byteswapping are more likely * to be detected. */ CFE_TEST_TestTable_t TestTable = {0xf007, 0xba11}; diff --git a/modules/core_api/config/default_cfe_core_api_interface_cfg.h b/modules/core_api/config/default_cfe_core_api_interface_cfg.h index 1f96eb73e..1a599eb55 100644 --- a/modules/core_api/config/default_cfe_core_api_interface_cfg.h +++ b/modules/core_api/config/default_cfe_core_api_interface_cfg.h @@ -129,4 +129,4 @@ */ #define CFE_MISSION_MAX_NUM_FILES 50 -#endif /* SAMPLE_MISSION_CFG_H */ +#endif /* CFE_CORE_API_INTERFACE_CFG_H */ diff --git a/modules/core_private/ut-stubs/inc/ut_support.h b/modules/core_private/ut-stubs/inc/ut_support.h index db77d19ca..fa3febde3 100644 --- a/modules/core_private/ut-stubs/inc/ut_support.h +++ b/modules/core_private/ut-stubs/inc/ut_support.h @@ -96,7 +96,7 @@ extern const char *UT_OSP_MESSAGES[]; */ #define UT_LITTLE_ENDIAN 1 #define UT_BIG_ENDIAN 2 -extern uint8 UT_Endianess; +extern uint8 UT_Endianness; typedef struct { diff --git a/modules/core_private/ut-stubs/src/ut_support.c b/modules/core_private/ut-stubs/src/ut_support.c index 01fbb07c0..88bc4a604 100644 --- a/modules/core_private/ut-stubs/src/ut_support.c +++ b/modules/core_private/ut-stubs/src/ut_support.c @@ -38,7 +38,7 @@ /* ** Global variables */ -uint8 UT_Endianess; +uint8 UT_Endianness; static char UT_appname[80]; static char UT_subsys[5]; @@ -110,11 +110,11 @@ void UT_Init(const char *subsys) if ((*(char *)&EndianCheck) == 0x04) { - UT_Endianess = UT_LITTLE_ENDIAN; + UT_Endianness = UT_LITTLE_ENDIAN; } else { - UT_Endianess = UT_BIG_ENDIAN; + UT_Endianness = UT_BIG_ENDIAN; } } diff --git a/modules/es/fsw/src/cfe_es_erlog.c b/modules/es/fsw/src/cfe_es_erlog.c index e65163a1c..125203b66 100644 --- a/modules/es/fsw/src/cfe_es_erlog.c +++ b/modules/es/fsw/src/cfe_es_erlog.c @@ -295,7 +295,7 @@ bool CFE_ES_RunExceptionScan(uint32 ElapsedTime, void *Arg) if (PspStatus != CFE_PSP_SUCCESS) { /* reason string is not available - populate with something for the PspStatus*/ - snprintf(ReasonString, sizeof(ReasonString), "Unknown - CFE_PSP_ExceptionGetSummary() error %ld", + snprintf(ReasonString, sizeof(ReasonString), "Unknown - CFE_PSP_Exception_GetSummary() error %ld", (long)PspStatus); PspContextId = 0; ExceptionTaskID = OS_OBJECT_ID_UNDEFINED; diff --git a/modules/es/ut-coverage/es_UT.c b/modules/es/ut-coverage/es_UT.c index 1511de87b..3c2d9ebaf 100644 --- a/modules/es/ut-coverage/es_UT.c +++ b/modules/es/ut-coverage/es_UT.c @@ -4237,7 +4237,7 @@ void TestAPI(void) AppId = CFE_ES_AppRecordGetID(UtAppRecPtr); CFE_UtAssert_SUCCESS(CFE_ES_GetAppName(AppName, AppId, sizeof(AppName))); - /* Bad arguement calls */ + /* Bad argument calls */ UtAssert_INT32_EQ(CFE_ES_GetAppName(NULL, AppId, sizeof(AppName)), CFE_ES_BAD_ARGUMENT); UtAssert_INT32_EQ(CFE_ES_GetAppName(AppName, AppId, 0), CFE_ES_BAD_ARGUMENT); diff --git a/modules/evs/ut-coverage/evs_UT.c b/modules/evs/ut-coverage/evs_UT.c index fa42ae1ea..02e481bf1 100644 --- a/modules/evs/ut-coverage/evs_UT.c +++ b/modules/evs/ut-coverage/evs_UT.c @@ -160,7 +160,7 @@ void UT_InitData_EVS(void) UT_SetHandlerFunction(UT_KEY(CFE_MSG_GetMsgTime), UT_CFE_MSG_GetMsgTime_CustomHandler, NULL); } -/* Message init hook to stora last MsgId passed in */ +/* Message init hook to store last MsgId passed in */ static int32 UT_EVS_MSGInitHook(void *UserObj, int32 StubRetcode, uint32 CallCount, const UT_StubContext_t *Context) { UT_EVS_MSGInitData_t *msgdataptr = UserObj; diff --git a/modules/fs/config/default_cfe_fs_filedef.h b/modules/fs/config/default_cfe_fs_filedef.h index b4450c975..1e8d213d5 100644 --- a/modules/fs/config/default_cfe_fs_filedef.h +++ b/modules/fs/config/default_cfe_fs_filedef.h @@ -195,4 +195,4 @@ typedef struct CFE_FS_Header char Description[CFE_FS_HDR_DESC_MAX_LEN]; /**< \brief File description */ } CFE_FS_Header_t; -#endif /* CFE_FS_EXTERN_TYPEDEFS_H */ +#endif /* CFE_FS_FILEHDR_H */ \ No newline at end of file diff --git a/modules/msg/fsw/src/cfe_msg_ccsdspri.c b/modules/msg/fsw/src/cfe_msg_ccsdspri.c index 664af7908..40a541b6c 100644 --- a/modules/msg/fsw/src/cfe_msg_ccsdspri.c +++ b/modules/msg/fsw/src/cfe_msg_ccsdspri.c @@ -262,6 +262,7 @@ CFE_Status_t CFE_MSG_GetSegmentationFlag(const CFE_MSG_Message_t *MsgPtr, CFE_MS case CFE_MSG_SEGFLG_UNSEG: default: *SegFlag = CFE_MSG_SegFlag_Unsegmented; + break; } return CFE_SUCCESS; @@ -300,6 +301,7 @@ CFE_Status_t CFE_MSG_SetSegmentationFlag(CFE_MSG_Message_t *MsgPtr, CFE_MSG_Segm case CFE_MSG_SegFlag_Invalid: default: status = CFE_MSG_BAD_ARGUMENT; + break; } if (status == CFE_SUCCESS) diff --git a/modules/sb/fsw/src/cfe_sb_api.c b/modules/sb/fsw/src/cfe_sb_api.c index bc4280ece..f78ae0b8a 100644 --- a/modules/sb/fsw/src/cfe_sb_api.c +++ b/modules/sb/fsw/src/cfe_sb_api.c @@ -245,7 +245,6 @@ CFE_Status_t CFE_SB_CreatePipe(CFE_SB_PipeId_t *PipeIdPtr, uint16 Depth, const c CFE_SB_GetAppTskName(TskId, FullName), (unsigned long)PipeIdPtr, (int)Depth, OS_QUEUE_MAX_DEPTH); break; - case CFE_SB_MAX_PIPES_MET_EID: CFE_EVS_SendEventWithAppID(CFE_SB_MAX_PIPES_MET_EID, CFE_EVS_EventType_ERROR, CFE_SB_Global.AppId, "CreatePipeErr:Max Pipes(%d)In Use.app %s", CFE_PLATFORM_SB_MAX_PIPES, @@ -266,6 +265,8 @@ CFE_Status_t CFE_SB_CreatePipe(CFE_SB_PipeId_t *PipeIdPtr, uint16 Depth, const c "CreatePipeErr:OS_QueueCreate returned %ld,app %s", (long)OsStatus, CFE_SB_GetAppTskName(TskId, FullName)); break; + default: + break; } } @@ -469,6 +470,8 @@ int32 CFE_SB_DeletePipeFull(CFE_SB_PipeId_t PipeId, CFE_ES_AppId_t AppId) "Pipe Delete Error:Caller(%s) is not the owner of pipe %ld", FullName, CFE_RESOURCEID_TO_ULONG(PipeId)); break; + default: + break; } } @@ -556,6 +559,8 @@ CFE_Status_t CFE_SB_SetPipeOpts(CFE_SB_PipeId_t PipeId, uint8 Opts) "Pipe Opts Set Error: Caller(%s) is not the owner of pipe %lu", CFE_SB_GetAppTskName(TskId, FullName), CFE_RESOURCEID_TO_ULONG(PipeId)); break; + default: + break; } } @@ -631,6 +636,8 @@ CFE_Status_t CFE_SB_GetPipeOpts(CFE_SB_PipeId_t PipeId, uint8 *OptsPtr) "Pipe Opts Error:Bad Argument,PipedId %lu,Requestor %s", CFE_RESOURCEID_TO_ULONG(PipeId), CFE_SB_GetAppTskName(TskId, FullName)); break; + default: + break; } } @@ -719,6 +726,8 @@ CFE_Status_t CFE_SB_GetPipeName(char *PipeNameBuf, size_t PipeNameSize, CFE_SB_P "Pipe Id Error:Bad Argument,Id=%lu,Requestor %s", CFE_RESOURCEID_TO_ULONG(PipeId), CFE_SB_GetAppTskName(TskId, FullName)); break; + default: + break; } if (PipeNameBuf != NULL && PipeNameSize > 0) @@ -828,6 +837,8 @@ CFE_Status_t CFE_SB_GetPipeIdByName(CFE_SB_PipeId_t *PipeIdPtr, const char *Pipe CFE_SB_Global.AppId, "Pipe ID By Name Error:Bad Argument,Requestor %s", CFE_SB_GetAppTskName(TskId, FullName)); break; + default: + break; } } @@ -1023,6 +1034,8 @@ int32 CFE_SB_SubscribeFull(CFE_SB_MsgId_t MsgId, CFE_SB_PipeId_t PipeId, CFE_SB_ case CFE_SB_DUP_SUBSCRIP_EID: CFE_SB_Global.HKTlmMsg.Payload.DuplicateSubscriptionsCounter++; break; + default: + break; } CFE_SB_UnlockSharedData(__func__, __LINE__); @@ -1081,6 +1094,8 @@ int32 CFE_SB_SubscribeFull(CFE_SB_MsgId_t MsgId, CFE_SB_PipeId_t PipeId, CFE_SB_ (unsigned int)CFE_SB_MsgIdToValue(MsgId), CFE_RESOURCEID_TO_ULONG(PipeId), CFE_SB_GetAppTskName(TskId, FullName), Scope); break; + default: + break; } } else if (Status == CFE_SUCCESS) @@ -1268,6 +1283,8 @@ int32 CFE_SB_UnsubscribeFull(CFE_SB_MsgId_t MsgId, CFE_SB_PipeId_t PipeId, uint8 (unsigned int)CFE_SB_MsgIdToValue(MsgId), CFE_RESOURCEID_TO_ULONG(PipeId), CFE_SB_GetAppTskName(TskId, FullName), (int)Scope); break; + default: + break; } } else if (Status == CFE_SUCCESS) @@ -1513,6 +1530,8 @@ int32 CFE_SB_TransmitMsgValidate(const CFE_MSG_Message_t *MsgPtr, CFE_SB_MsgId_t CFE_SB_FinishSendEvent(TskId, CFE_SB_SEND_NO_SUBS_EID_BIT); } break; + default: + break; } } @@ -1983,6 +2002,8 @@ CFE_Status_t CFE_SB_ReceiveBuffer(CFE_SB_Buffer_t **BufPtr, CFE_SB_PipeId_t Pipe "Rcv Err:PipeId %lu does not exist,app %s", CFE_RESOURCEID_TO_ULONG(PipeId), CFE_SB_GetAppTskName(TskId, FullName)); break; + default: + break; } } diff --git a/modules/sb/fsw/src/cfe_sb_task.c b/modules/sb/fsw/src/cfe_sb_task.c index e3168d8a7..b27b859e0 100644 --- a/modules/sb/fsw/src/cfe_sb_task.c +++ b/modules/sb/fsw/src/cfe_sb_task.c @@ -442,6 +442,8 @@ int32 CFE_SB_EnableRouteCmd(const CFE_SB_EnableRouteCmd_t *data) CFE_EVS_SendEvent(CFE_SB_ENBL_RTE2_EID, CFE_EVS_EventType_DEBUG, "Enabling Route,Msg 0x%x,Pipe %lu", (unsigned int)CFE_SB_MsgIdToValue(MsgId), CFE_RESOURCEID_TO_ULONG(CmdPtr->Pipe)); break; + default: + break; } return CFE_SUCCESS; @@ -509,6 +511,8 @@ int32 CFE_SB_DisableRouteCmd(const CFE_SB_DisableRouteCmd_t *data) CFE_EVS_SendEvent(CFE_SB_DSBL_RTE2_EID, CFE_EVS_EventType_DEBUG, "Route Disabled,Msg 0x%x,Pipe %lu", (unsigned int)CFE_SB_MsgIdToValue(MsgId), CFE_RESOURCEID_TO_ULONG(CmdPtr->Pipe)); break; + default: + break; } return CFE_SUCCESS; diff --git a/modules/sb/ut-coverage/sb_UT.c b/modules/sb/ut-coverage/sb_UT.c index b6b7cb141..76b565ad3 100644 --- a/modules/sb/ut-coverage/sb_UT.c +++ b/modules/sb/ut-coverage/sb_UT.c @@ -1614,7 +1614,7 @@ void Test_SB_EarlyInit_NoErrors(void) CFE_SB_EarlyInit(); CFE_UtAssert_SUCCESS(CFE_SB_EarlyInit()); - /* Confirm reset of values to cover reset requirements that are challenging operationaly */ + /* Confirm reset of values to cover reset requirements that are challenging operationally */ UtAssert_ZERO(CFE_SB_Global.HKTlmMsg.Payload.CommandErrorCounter); UtAssert_ZERO(CFE_SB_Global.HKTlmMsg.Payload.NoSubscribersCounter); UtAssert_ZERO(CFE_SB_Global.HKTlmMsg.Payload.MsgSendErrorCounter); @@ -3647,7 +3647,7 @@ static void SB_UT_PipeIdModifyHandler(void *UserObj, UT_EntryKey_t FuncKey, cons PipeDscPtr->PipeId = CFE_SB_INVALID_PIPE; } -/* Special handler to hit OS_QueueGet error casses */ +/* Special handler to hit OS_QueueGet error cases */ static void SB_UT_QueueGetHandler(void *UserObj, UT_EntryKey_t FuncKey, const UT_StubContext_t *Context) { size_t **data = (size_t **)UT_Hook_GetArgValueByName(Context, "data", void *); @@ -4238,14 +4238,14 @@ void Test_SB_SpecialCases(void) } /* - * Test the use count rollover prevetion + * Test the use count rollover prevention */ void Test_UseCount_Rollover_Prevention(void) { CFE_SB_BufferD_t bd; uint16 usecount_expected = 0x7FFF; - /* Note this is just for coverage, limit can not be reached in nomal ops (would be a bug) */ + /* Note this is just for coverage, limit can not be reached in normal ops (would be a bug) */ bd.UseCount = usecount_expected; UtAssert_VOIDCALL(CFE_SB_IncrBufUseCnt(&bd)); UtAssert_UINT32_EQ(bd.UseCount, usecount_expected); diff --git a/modules/tbl/fsw/src/cfe_tbl_api.c b/modules/tbl/fsw/src/cfe_tbl_api.c index 5333557b7..fd98a25b7 100644 --- a/modules/tbl/fsw/src/cfe_tbl_api.c +++ b/modules/tbl/fsw/src/cfe_tbl_api.c @@ -504,6 +504,7 @@ CFE_Status_t CFE_TBL_Load(CFE_TBL_Handle_t TblHandle, CFE_TBL_SrcEnum_t SrcType, "%s: Attempted to load from illegal source type=%d", AppName, (int)SrcType); Status = CFE_TBL_ERR_ILLEGAL_SRC_TYPE; + break; } /* If the data was successfully loaded, then validate its contents */ diff --git a/modules/tbl/ut-coverage/tbl_UT.c b/modules/tbl/ut-coverage/tbl_UT.c index b130539d4..cbbbcc7c1 100644 --- a/modules/tbl/ut-coverage/tbl_UT.c +++ b/modules/tbl/ut-coverage/tbl_UT.c @@ -106,7 +106,7 @@ void UT_TBL_SetupHeader(CFE_TBL_File_Hdr_t *TblFileHeader, size_t Offset, size_t TblFileHeader->Offset = Offset; TblFileHeader->NumBytes = NumBytes; - if (UT_Endianess == UT_LITTLE_ENDIAN) + if (UT_Endianness == UT_LITTLE_ENDIAN) { CFE_TBL_ByteSwapUint32(&TblFileHeader->Offset); CFE_TBL_ByteSwapUint32(&TblFileHeader->NumBytes); @@ -1260,7 +1260,7 @@ void Test_CFE_TBL_LoadCmd(void) UT_SetReadHeader(&StdFileHeader, sizeof(StdFileHeader)); UtAssert_INT32_EQ(CFE_TBL_LoadCmd(&LoadCmd), CFE_TBL_INC_ERR_CTR); - /* Test with interal CFE_TBL_GetWorkingBuffer error (memcpy with matching address */ + /* Test with internal CFE_TBL_GetWorkingBuffer error (memcpy with matching address */ UT_InitData(); CFE_TBL_Global.Registry[0].LoadInProgress = CFE_TBL_NO_LOAD_IN_PROGRESS; CFE_TBL_Global.Registry[0].TableLoadedOnce = true; @@ -2432,7 +2432,7 @@ void Test_CFE_TBL_ReleaseAddresses(void) File.TblHeader.TableName[sizeof(File.TblHeader.TableName) - 1] = '\0'; UT_TBL_SetupHeader(&File.TblHeader, 0, sizeof(UT_Table1_t)); - if (UT_Endianess == UT_LITTLE_ENDIAN) + if (UT_Endianness == UT_LITTLE_ENDIAN) { File.TblData.TblElement1 = 0x04030201; File.TblData.TblElement2 = 0x08070605; @@ -3091,7 +3091,7 @@ void Test_CFE_TBL_TblMod(void) File.TblHeader.TableName[sizeof(File.TblHeader.TableName) - 1] = '\0'; UT_TBL_SetupHeader(&File.TblHeader, 0, sizeof(UT_Table1_t)); - if (UT_Endianess == UT_LITTLE_ENDIAN) + if (UT_Endianness == UT_LITTLE_ENDIAN) { File.TblData.TblElement1 = 0x04030201; File.TblData.TblElement2 = 0x08070605; @@ -3442,7 +3442,7 @@ void Test_CFE_TBL_Internal(void) TblFileHeader.NumBytes = sizeof(UT_Table1_t) - 1; TblFileHeader.Offset = 0; - if (UT_Endianess == UT_LITTLE_ENDIAN) + if (UT_Endianness == UT_LITTLE_ENDIAN) { CFE_TBL_ByteSwapUint32(&TblFileHeader.NumBytes); CFE_TBL_ByteSwapUint32(&TblFileHeader.Offset); @@ -3910,7 +3910,7 @@ void Test_CFE_TBL_Internal(void) TblFileHeader.NumBytes = sizeof(UT_Table1_t) - 1; TblFileHeader.Offset = 0; - if (UT_Endianess == UT_LITTLE_ENDIAN) + if (UT_Endianness == UT_LITTLE_ENDIAN) { CFE_TBL_ByteSwapUint32(&TblFileHeader.NumBytes); CFE_TBL_ByteSwapUint32(&TblFileHeader.Offset); @@ -3940,7 +3940,7 @@ void Test_CFE_TBL_Internal(void) TblFileHeader.NumBytes = sizeof(UT_Table1_t) - 1; TblFileHeader.Offset = 0; - if (UT_Endianess == UT_LITTLE_ENDIAN) + if (UT_Endianness == UT_LITTLE_ENDIAN) { CFE_TBL_ByteSwapUint32(&TblFileHeader.NumBytes); CFE_TBL_ByteSwapUint32(&TblFileHeader.Offset);