Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix #382, Replace exit(1) and exit(-1) with EXIT_FAILURE macro #383

Merged

Conversation

thnkslprpt
Copy link
Contributor

@thnkslprpt thnkslprpt commented Mar 13, 2023

Checklist

Describe the contribution

Note: A single case was replaced with EXIT_SUCCESS in CFE_PSP_DisplayUsage() - this call to exit() seems to be there simply to explicitly end execution of the function (it's a void function) so I assume there is no difference between exiting with SUCCESS or FAILURE.

Testing performed
GitHub CI actions all passing successfully.
Tested locally to confirm no change to test outcomes or coverage.

Expected behavior changes
No change to behavior.
The macros are more expressive and potentially more portable.

System(s) tested on
Intel(R) Celeron(R) N4100 CPU @ 1.10GHz x86_64
Debian GNU/Linux 11 (bullseye)
Current main branch of cFS.

Contributor Info
Avi Weiss @thnkslprpt

@thnkslprpt thnkslprpt force-pushed the fix-382-replace-exit-1-with-exit-failure branch from c856201 to ad03fc8 Compare March 14, 2023 13:07
Copy link
Contributor

@jphickey jphickey left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Minor request

fsw/pc-linux/src/cfe_psp_start.c Outdated Show resolved Hide resolved
@thnkslprpt thnkslprpt requested a review from jphickey April 6, 2023 20:58
@thnkslprpt thnkslprpt force-pushed the fix-382-replace-exit-1-with-exit-failure branch from ad03fc8 to cdc524f Compare April 6, 2023 20:58
@thnkslprpt thnkslprpt force-pushed the fix-382-replace-exit-1-with-exit-failure branch from cdc524f to 9a47a7e Compare December 11, 2023 20:58
@thnkslprpt thnkslprpt force-pushed the fix-382-replace-exit-1-with-exit-failure branch from 9a47a7e to 6ccf27b Compare December 11, 2023 21:00
@skliper skliper added the CCB:Ready Pull request is ready for discussion at the Configuration Control Board (CCB) label Dec 12, 2023
@skliper
Copy link
Contributor

skliper commented Dec 12, 2023

@dzbaker Recommending CCB review/merge

@dmknutsen dmknutsen added the CCB:Approved Indicates Approval by CCB label Dec 14, 2023
@dmknutsen dmknutsen removed the CCB:Ready Pull request is ready for discussion at the Configuration Control Board (CCB) label Dec 15, 2023
@dmknutsen dmknutsen merged commit f27c73e into nasa:main Dec 15, 2023
10 of 11 checks passed
@thnkslprpt thnkslprpt deleted the fix-382-replace-exit-1-with-exit-failure branch December 15, 2023 20:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CCB:Approved Indicates Approval by CCB
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Replace exit(1) and exit(-1) with preferred macro EXIT_FAILURE
4 participants