@@ -58,8 +58,8 @@ int32 FM_ChildInit(void)
5858{
5959 int32 TaskTextLen = OS_MAX_PATH_LEN ;
6060 char TaskText [OS_MAX_PATH_LEN ] = "\0" ;
61- int32 Result = CFE_SUCCESS ;
62- uint32 TaskEID = 0 ;
61+ int32 Result ;
62+ uint32 TaskEID = 0 ;
6363
6464 /* Create counting semaphore (given by parent to wake-up child) */
6565 Result = OS_CountSemCreate (& FM_GlobalData .ChildSemaphore , FM_CHILD_SEM_NAME , 0 , 0 );
@@ -279,8 +279,8 @@ void FM_ChildProcess(void)
279279
280280void FM_ChildCopyCmd (const FM_ChildQueueEntry_t * CmdArgs )
281281{
282- const char * CmdText = "Copy File" ;
283- int32 OS_Status = OS_SUCCESS ;
282+ const char * CmdText = "Copy File" ;
283+ int32 OS_Status ;
284284
285285 /* Report current child task activity */
286286 FM_GlobalData .ChildCurrentCC = CmdArgs -> CommandCode ;
@@ -319,8 +319,8 @@ void FM_ChildCopyCmd(const FM_ChildQueueEntry_t *CmdArgs)
319319
320320void FM_ChildMoveCmd (const FM_ChildQueueEntry_t * CmdArgs )
321321{
322- const char * CmdText = "Move File" ;
323- int32 OS_Status = OS_SUCCESS ;
322+ const char * CmdText = "Move File" ;
323+ int32 OS_Status ;
324324
325325 /* Report current child task activity */
326326 FM_GlobalData .ChildCurrentCC = CmdArgs -> CommandCode ;
@@ -358,8 +358,8 @@ void FM_ChildMoveCmd(const FM_ChildQueueEntry_t *CmdArgs)
358358
359359void FM_ChildRenameCmd (const FM_ChildQueueEntry_t * CmdArgs )
360360{
361- const char * CmdText = "Rename File" ;
362- int32 OS_Status = OS_SUCCESS ;
361+ const char * CmdText = "Rename File" ;
362+ int32 OS_Status ;
363363
364364 /* Report current child task activity */
365365 FM_GlobalData .ChildCurrentCC = CmdArgs -> CommandCode ;
@@ -397,8 +397,8 @@ void FM_ChildRenameCmd(const FM_ChildQueueEntry_t *CmdArgs)
397397
398398void FM_ChildDeleteCmd (const FM_ChildQueueEntry_t * CmdArgs )
399399{
400- const char * CmdText = "Delete File" ;
401- int32 OS_Status = OS_SUCCESS ;
400+ const char * CmdText = "Delete File" ;
401+ int32 OS_Status ;
402402
403403 /* Report current child task activity */
404404 FM_GlobalData .ChildCurrentCC = CmdArgs -> CommandCode ;
@@ -439,7 +439,7 @@ void FM_ChildDeleteAllFilesCmd(FM_ChildQueueEntry_t *CmdArgs)
439439 const char * CmdText = "Delete All Files" ;
440440 osal_id_t DirId = OS_OBJECT_ID_UNDEFINED ;
441441 os_dirent_t DirEntry ;
442- int32 OS_Status = OS_SUCCESS ;
442+ int32 OS_Status ;
443443 uint32 FilenameState = FM_NAME_IS_INVALID ;
444444 uint32 NameLength = 0 ;
445445 uint32 DeleteCount = 0 ;
@@ -587,8 +587,8 @@ void FM_ChildDeleteAllFilesCmd(FM_ChildQueueEntry_t *CmdArgs)
587587
588588void FM_ChildDecompressFileCmd (const FM_ChildQueueEntry_t * CmdArgs )
589589{
590- const char * CmdText = "Decompress File" ;
591- int32 CFE_Status = CFE_SUCCESS ;
590+ const char * CmdText = "Decompress File" ;
591+ int32 CFE_Status ;
592592
593593 /* Report current child task activity */
594594 FM_GlobalData .ChildCurrentCC = CmdArgs -> CommandCode ;
@@ -634,11 +634,11 @@ void FM_ChildConcatFilesCmd(const FM_ChildQueueEntry_t *CmdArgs)
634634 bool OpenedSource2 = false;
635635 bool OpenedTgtFile = false;
636636 int32 LoopCount = 0 ;
637- int32 OS_Status = OS_SUCCESS ;
638- osal_id_t FileHandleSrc = OS_OBJECT_ID_UNDEFINED ;
639- osal_id_t FileHandleTgt = OS_OBJECT_ID_UNDEFINED ;
640- int32 BytesRead = 0 ;
641- int32 BytesWritten = 0 ;
637+ int32 OS_Status ;
638+ osal_id_t FileHandleSrc = OS_OBJECT_ID_UNDEFINED ;
639+ osal_id_t FileHandleTgt = OS_OBJECT_ID_UNDEFINED ;
640+ int32 BytesRead = 0 ;
641+ int32 BytesWritten = 0 ;
642642
643643 /* Report current child task activity */
644644 FM_GlobalData .ChildCurrentCC = CmdArgs -> CommandCode ;
@@ -963,8 +963,8 @@ void FM_ChildFileInfoCmd(FM_ChildQueueEntry_t *CmdArgs)
963963
964964void FM_ChildCreateDirectoryCmd (const FM_ChildQueueEntry_t * CmdArgs )
965965{
966- const char * CmdText = "Create Directory" ;
967- int32 OS_Status = OS_SUCCESS ;
966+ const char * CmdText = "Create Directory" ;
967+ int32 OS_Status ;
968968
969969 /* Report current child task activity */
970970 FM_GlobalData .ChildCurrentCC = CmdArgs -> CommandCode ;
@@ -1006,7 +1006,7 @@ void FM_ChildDeleteDirectoryCmd(const FM_ChildQueueEntry_t *CmdArgs)
10061006 bool RemoveTheDir = true;
10071007 osal_id_t DirId = OS_OBJECT_ID_UNDEFINED ;
10081008 os_dirent_t DirEntry ;
1009- int32 OS_Status = OS_SUCCESS ;
1009+ int32 OS_Status ;
10101010
10111011 memset (& DirEntry , 0 , sizeof (DirEntry ));
10121012
@@ -1080,11 +1080,11 @@ void FM_ChildDeleteDirectoryCmd(const FM_ChildQueueEntry_t *CmdArgs)
10801080
10811081void FM_ChildDirListFileCmd (const FM_ChildQueueEntry_t * CmdArgs )
10821082{
1083- const char * CmdText = "Directory List to File" ;
1084- bool Result = false ;
1083+ const char * CmdText = "Directory List to File" ;
1084+ bool Result ;
10851085 osal_id_t FileHandle = OS_OBJECT_ID_UNDEFINED ;
10861086 osal_id_t DirId = OS_OBJECT_ID_UNDEFINED ;
1087- int32 Status = 0 ;
1087+ int32 Status ;
10881088
10891089 /* Report current child task activity */
10901090 FM_GlobalData .ChildCurrentCC = CmdArgs -> CommandCode ;
@@ -1142,12 +1142,12 @@ void FM_ChildDirListPktCmd(const FM_ChildQueueEntry_t *CmdArgs)
11421142{
11431143 const char * CmdText = "Directory List to Packet" ;
11441144 char LogicalName [OS_MAX_PATH_LEN ] = "\0" ;
1145- bool StillProcessing = true ;
1146- osal_id_t DirId = OS_OBJECT_ID_UNDEFINED ;
1145+ bool StillProcessing ;
1146+ osal_id_t DirId = OS_OBJECT_ID_UNDEFINED ;
11471147 os_dirent_t DirEntry ;
1148- int32 ListIndex = 0 ;
1149- FM_DirListEntry_t * ListEntry = NULL ;
1150- int32 PathLength = 0 ;
1148+ int32 ListIndex = 0 ;
1149+ FM_DirListEntry_t * ListEntry = NULL ;
1150+ int32 PathLength ;
11511151 int32 EntryLength = 0 ;
11521152 int32 FilesTillSleep = FM_CHILD_STAT_SLEEP_FILECOUNT ;
11531153 int32 Status ;
@@ -1275,8 +1275,8 @@ void FM_ChildDirListPktCmd(const FM_ChildQueueEntry_t *CmdArgs)
12751275/* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
12761276void FM_ChildSetPermissionsCmd (const FM_ChildQueueEntry_t * CmdArgs )
12771277{
1278- int32 OS_Status = OS_SUCCESS ;
1279- const char * CmdText = "Set Permissions" ;
1278+ int32 OS_Status ;
1279+ const char * CmdText = "Set Permissions" ;
12801280
12811281 OS_Status = OS_chmod (CmdArgs -> Source1 , CmdArgs -> Mode );
12821282
@@ -1316,7 +1316,7 @@ bool FM_ChildDirListFileInit(osal_id_t *FileHandlePtr, const char *Directory, co
13161316 CFE_FS_Header_t FileHeader ;
13171317 osal_id_t FileHandle = OS_OBJECT_ID_UNDEFINED ;
13181318 int32 BytesWritten = 0 ;
1319- int32 Status = 0 ;
1319+ int32 Status ;
13201320
13211321 /* Initialize the standard cFE File Header for the Directory Listing File */
13221322 CFE_FS_InitHeader (& FileHeader , CmdText , FM_DIR_LIST_FILE_SUBTYPE );
@@ -1392,17 +1392,17 @@ bool FM_ChildDirListFileInit(osal_id_t *FileHandlePtr, const char *Directory, co
13921392void FM_ChildDirListFileLoop (osal_id_t DirId , osal_id_t FileHandle , const char * Directory , const char * DirWithSep ,
13931393 const char * Filename , uint8 getSizeTimeMode )
13941394{
1395- const char * CmdText = "Directory List to File" ;
1396- int32 WriteLength = sizeof (FM_DirListEntry_t );
1397- bool ReadingDirectory = true;
1398- bool CommandResult = true;
1399- uint32 DirEntries = 0 ;
1400- uint32 FileEntries = 0 ;
1401- int32 EntryLength = 0 ;
1402- int32 PathLength = 0 ;
1403- int32 BytesWritten = 0 ;
1404- int32 FilesTillSleep = FM_CHILD_STAT_SLEEP_FILECOUNT ;
1405- int32 Status = 0 ;
1395+ const char * CmdText = "Directory List to File" ;
1396+ int32 WriteLength = sizeof (FM_DirListEntry_t );
1397+ bool ReadingDirectory = true;
1398+ bool CommandResult = true;
1399+ uint32 DirEntries = 0 ;
1400+ uint32 FileEntries = 0 ;
1401+ int32 EntryLength = 0 ;
1402+ int32 PathLength ;
1403+ int32 BytesWritten = 0 ;
1404+ int32 FilesTillSleep = FM_CHILD_STAT_SLEEP_FILECOUNT ;
1405+ int32 Status ;
14061406 char TempName [OS_MAX_PATH_LEN ] = "\0" ;
14071407 os_dirent_t DirEntry ;
14081408 FM_DirListEntry_t DirListData ;
@@ -1529,7 +1529,7 @@ void FM_ChildDirListFileLoop(osal_id_t DirId, osal_id_t FileHandle, const char *
15291529
15301530int32 FM_ChildSizeTimeMode (const char * Filename , uint32 * FileSize , uint32 * FileTime , uint32 * FileMode )
15311531{
1532- int32 Result = OS_SUCCESS ;
1532+ int32 Result ;
15331533 os_fstat_t FileStatus ;
15341534
15351535 memset (& FileStatus , 0 , sizeof (FileStatus ));
0 commit comments