Skip to content

Commit

Permalink
Merge pull request #2138 from skliper/fix2137-uninit_vars
Browse files Browse the repository at this point in the history
Fix #2137, Squash uninit var static analysis warnings
  • Loading branch information
dzbaker committed Aug 25, 2022
2 parents 318f345 + 84b4286 commit 486df76
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion modules/cfe_testcase/src/sb_sendrecv_test.c
Original file line number Diff line number Diff line change
Expand Up @@ -226,7 +226,7 @@ void TestMsgBroadcast(void)
CFE_SB_PipeId_t PipeId3 = CFE_SB_INVALID_PIPE;
CFE_SB_PipeId_t PipeId4 = CFE_SB_INVALID_PIPE;
CFE_FT_TestCmdMessage_t CmdMsg;
CFE_SB_MsgId_t MsgId;
CFE_SB_MsgId_t MsgId = CFE_SB_INVALID_MSG_ID;
CFE_SB_Buffer_t * MsgBuf1;
CFE_SB_Buffer_t * MsgBuf2;
CFE_SB_Buffer_t * MsgBuf3;
Expand Down
2 changes: 1 addition & 1 deletion modules/evs/fsw/src/cfe_evs_utils.c
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ bool EVS_CheckAndIncrementSquelchTokens(EVS_AppData_t *AppDataPtr)
{
bool NotSquelched = true;
bool SendSquelchEvent = false;
OS_time_t CurrentTime;
OS_time_t CurrentTime = {0};
int64 DeltaTimeMs;
int64 CreditCount;
char AppName[OS_MAX_API_NAME];
Expand Down
3 changes: 3 additions & 0 deletions modules/evs/ut-coverage/evs_UT.c
Original file line number Diff line number Diff line change
Expand Up @@ -267,6 +267,9 @@ void Test_Init(void)

UtPrintf("Begin Test Init");

memset(&bitmaskcmd, 0, sizeof(bitmaskcmd));
memset(&appbitcmd, 0, sizeof(appbitcmd));

strncpy(appbitcmd.Payload.AppName, "ut_cfe_evs", sizeof(appbitcmd.Payload.AppName) - 1);
appbitcmd.Payload.AppName[sizeof(appbitcmd.Payload.AppName) - 1] = '\0';

Expand Down

0 comments on commit 486df76

Please sign in to comment.