From ba8b09bedfd8befe2300c1341f32259eab56e4d1 Mon Sep 17 00:00:00 2001 From: havencarlson Date: Mon, 8 Aug 2022 14:26:20 -0400 Subject: [PATCH] Fix #8, remove return statements from void functions --- fsw/src/fm_app.c | 6 ------ fsw/src/fm_child.c | 33 --------------------------------- fsw/src/fm_cmd_utils.c | 4 ---- fsw/src/fm_tbl.c | 4 ---- 4 files changed, 47 deletions(-) diff --git a/fsw/src/fm_app.c b/fsw/src/fm_app.c index 675b96f..99aa397 100644 --- a/fsw/src/fm_app.c +++ b/fsw/src/fm_app.c @@ -272,8 +272,6 @@ void FM_ProcessPkt(const CFE_SB_Buffer_t *BufPtr) break; } - return; - } /* End of FM_ProcessPkt */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -388,8 +386,6 @@ void FM_ProcessCmd(const CFE_SB_Buffer_t *BufPtr) FM_GlobalData.CommandErrCounter++; } - return; - } // End of FM_ProcessCmd /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -436,8 +432,6 @@ void FM_ReportHK(const CFE_MSG_CommandHeader_t *Msg) CFE_SB_TransmitMsg(&FM_GlobalData.HousekeepingPkt.TlmHeader.Msg, true); } - return; - } // End of FM_ReportHK /************************/ diff --git a/fsw/src/fm_child.c b/fsw/src/fm_child.c index 8c46d03..b278c6d 100644 --- a/fsw/src/fm_child.c +++ b/fsw/src/fm_child.c @@ -134,8 +134,6 @@ void FM_ChildTask(void) /* This call allows cFE to clean-up system resources */ CFE_ES_ExitChildTask(); - return; - } /* End of FM_ChildTask() */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -192,8 +190,6 @@ void FM_ChildLoop(void) CFE_ES_PerfLogExit(FM_CHILD_TASK_PERF_ID); } - return; - } /* End of FM_ChildLoop() */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -286,8 +282,6 @@ void FM_ChildProcess(void) FM_GlobalData.ChildQueueCount--; OS_MutSemGive(FM_GlobalData.ChildQueueCountSem); - return; - } /* End of FM_ChildProcess() */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -329,8 +323,6 @@ void FM_ChildCopyCmd(const FM_ChildQueueEntry_t *CmdArgs) FM_GlobalData.ChildPreviousCC = CmdArgs->CommandCode; FM_GlobalData.ChildCurrentCC = 0; - return; - } /* End of FM_ChildCopyCmd() */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -371,8 +363,6 @@ void FM_ChildMoveCmd(const FM_ChildQueueEntry_t *CmdArgs) FM_GlobalData.ChildPreviousCC = CmdArgs->CommandCode; FM_GlobalData.ChildCurrentCC = 0; - return; - } /* End of FM_ChildMoveCmd() */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -413,8 +403,6 @@ void FM_ChildRenameCmd(const FM_ChildQueueEntry_t *CmdArgs) FM_GlobalData.ChildPreviousCC = CmdArgs->CommandCode; FM_GlobalData.ChildCurrentCC = 0; - return; - } /* End of FM_ChildRenameCmd() */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -458,8 +446,6 @@ void FM_ChildDeleteCmd(const FM_ChildQueueEntry_t *CmdArgs) FM_GlobalData.ChildPreviousCC = CmdArgs->CommandCode; FM_GlobalData.ChildCurrentCC = 0; - return; - } /* End of FM_ChildDeleteCmd() */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -612,8 +598,6 @@ void FM_ChildDeleteAllCmd(FM_ChildQueueEntry_t *CmdArgs) FM_GlobalData.ChildPreviousCC = CmdArgs->CommandCode; FM_GlobalData.ChildCurrentCC = 0; - return; - } /* End of FM_ChildDeleteAllCmd() */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -657,8 +641,6 @@ void FM_ChildDecompressCmd(const FM_ChildQueueEntry_t *CmdArgs) FM_GlobalData.ChildPreviousCC = CmdArgs->CommandCode; FM_GlobalData.ChildCurrentCC = 0; - return; - } /* End of FM_ChildDecompressCmd() */ #endif @@ -836,8 +818,6 @@ void FM_ChildConcatCmd(const FM_ChildQueueEntry_t *CmdArgs) FM_GlobalData.ChildPreviousCC = CmdArgs->CommandCode; FM_GlobalData.ChildCurrentCC = 0; - return; - } /* End of FM_ChildConcatCmd() */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -997,8 +977,6 @@ void FM_ChildFileInfoCmd(FM_ChildQueueEntry_t *CmdArgs) FM_GlobalData.ChildPreviousCC = CmdArgs->CommandCode; FM_GlobalData.ChildCurrentCC = 0; - return; - } /* End of FM_ChildFileInfoCmd() */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -1039,8 +1017,6 @@ void FM_ChildCreateDirCmd(const FM_ChildQueueEntry_t *CmdArgs) FM_GlobalData.ChildPreviousCC = CmdArgs->CommandCode; FM_GlobalData.ChildCurrentCC = 0; - return; - } /* End of FM_ChildCreateDirCmd() */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -1120,8 +1096,6 @@ void FM_ChildDeleteDirCmd(const FM_ChildQueueEntry_t *CmdArgs) FM_GlobalData.ChildPreviousCC = CmdArgs->CommandCode; FM_GlobalData.ChildCurrentCC = 0; - return; - } /* End of FM_ChildDeleteDirCmd() */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -1183,8 +1157,6 @@ void FM_ChildDirListFileCmd(const FM_ChildQueueEntry_t *CmdArgs) FM_GlobalData.ChildPreviousCC = CmdArgs->CommandCode; FM_GlobalData.ChildCurrentCC = 0; - return; - } /* End of FM_ChildDirListFileCmd() */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -1319,8 +1291,6 @@ void FM_ChildDirListPktCmd(const FM_ChildQueueEntry_t *CmdArgs) FM_GlobalData.ChildPreviousCC = CmdArgs->CommandCode; FM_GlobalData.ChildCurrentCC = 0; - return; - } /* End of FM_ChildDirListPktCmd() */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -1357,7 +1327,6 @@ void FM_ChildSetPermissionsCmd(const FM_ChildQueueEntry_t *CmdArgs) FM_GlobalData.ChildPreviousCC = CmdArgs->CommandCode; FM_GlobalData.ChildCurrentCC = 0; - return; } /* End of FM_ChildSetPermissionsCmd() */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -1578,8 +1547,6 @@ void FM_ChildDirListFileLoop(osal_id_t DirId, osal_id_t FileHandle, const char * (int)DirEntries, Directory, Filename); } - return; - } /* End of FM_ChildDirListFileLoop */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ diff --git a/fsw/src/fm_cmd_utils.c b/fsw/src/fm_cmd_utils.c index ae880e9..76b5a9f 100644 --- a/fsw/src/fm_cmd_utils.c +++ b/fsw/src/fm_cmd_utils.c @@ -595,8 +595,6 @@ void FM_InvokeChildTask(void) OS_CountSemGive(FM_GlobalData.ChildSemaphore); } - return; - } /* End of FM_InvokeChildTask */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -630,8 +628,6 @@ void FM_AppendPathSep(char *Directory, uint32 BufferSize) } } - return; - } /* End of FM_AppendPathSep */ /************************/ diff --git a/fsw/src/fm_tbl.c b/fsw/src/fm_tbl.c index e135af1..a84b9d5 100644 --- a/fsw/src/fm_tbl.c +++ b/fsw/src/fm_tbl.c @@ -202,8 +202,6 @@ void FM_AcquireTablePointers(void) FM_GlobalData.FreeSpaceTablePtr = (FM_FreeSpaceTable_t *)NULL; } - return; - } /* End FM_AcquireTablePointers */ /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */ @@ -220,8 +218,6 @@ void FM_ReleaseTablePointers(void) /* Prevent table pointer use while released */ FM_GlobalData.FreeSpaceTablePtr = (FM_FreeSpaceTable_t *)NULL; - return; - } /* End FM_ReleaseTablePointers */ /************************/