-
Notifications
You must be signed in to change notification settings - Fork 228
Closed
Description
Describe the bug
CFE_ES_ExitApp reports error when passed in ExitStatus is CFE_ES_RunStatus_APP_RUN.
Typical app pattern (see https://github.com/nasa/sample_app/blob/master/fsw/src/sample_app.c) is:
while (CFE_ES_RunLoop(&Sample_AppData.RunStatus) == TRUE) {do stuff}
CFE_ES_ExitApp(Sample_AppData.RunStatus);
But CFE_ES_RunLoop does not update RunStatus on internal request to stop:
cFE/fsw/cfe-core/src/es/cfe_es_api.c
Lines 545 to 552 in 7251cbc
| if ( CFE_ES_Global.AppTable[AppID].ControlReq.AppControlRequest != CFE_ES_RunStatus_APP_RUN ) | |
| { | |
| /* | |
| ** We have an external request to stop | |
| */ | |
| ReturnCode = false; | |
| } |
To Reproduce
Steps to reproduce the behavior:
- Send RestartApp, will error and fail to restart.
Expected behavior
Set passed in RunStatus to the control request for the case above:
RunStatus = CFE_ES_Global.AppTable[AppID].ControlReq.AppControlRequest
Allows the App to take appropriate action.
System observed on:
- cFS Dev Server
- OS: Ubuntu 18.04
- Versions: current dev (6.7.4)
Additional context
Fails build verification testing
Reporter Info
Jacob Hageman - NASA/GSFC