cFE
cFE copied to clipboard
Fix #1428, Refactor error handling for EVS_GetApplicationInfo()
Checklist
- [x] I reviewed the Contributing Guide.
- [x] I signed and emailed the appropriate Contributor License Agreement to [email protected] and copied [email protected].
Describe the contribution
- Fixes #1428
- Refactors (10 cases of) identical handling of error returns from
EVS_GetApplicationInfo()into a single helper function.
- Refactors (10 cases of) identical handling of error returns from
The function prototype isn't strictly required, given the placement of the function definition, but is probably worth having to improve clarity and ease future maintenance.
Can also be implemented as an if/else if/else block (see below). No strong preference but I've left it as a switch for now.

Testing performed GitHub CI actions (incl. Build + Run, Unit Tests etc.) all passing successfully. Tested locally as well and confirmed coverage of all new/amended lines of code via LCOV report.
Expected behavior changes No impact on behavior. The same events will occur in the same circumstances.
System(s) tested on Intel(R) Celeron(R) N4100 CPU @ 1.10GHz x86_64 Debian GNU/Linux 11 (bullseye) Current main branch cFS bundle. cFE v7.0.0-rc4+dev205
Contributor Info Avi Weiss @thnkslprpt
Question: Does this require new tests, or is the coverage coming through from the calling functions satisfactory?
You have successfully added a new CodeQL configuration coding-standard. As part of the setup process, we have scanned this repository and found 1906 existing alerts. Please check the repository Security tab to see all alerts.
You have successfully added a new CodeQL configuration security. As part of the setup process, we have scanned this repository and found 30 existing alerts. Please check the repository Security tab to see all alerts.