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 #1726, mark read only inputs as const #1765

Merged

Conversation

jphickey
Copy link
Contributor

@jphickey jphickey commented Aug 5, 2021

Describe the contribution
The following functions have read-only inputs which are passed by pointer, so it should be "const" qualified:

CFE_ES_CopyToCDS
CFE_SB_TransmitMsg
CFE_SB_TransmitMsgValidate

Fixes #1726

Testing performed
Build and sanity check CFE, run all tests

Expected behavior changes
None, input was already read only, this just corrects the prototype to reflect that.

System(s) tested on
Ubuntu

Contributor Info - All information REQUIRED for consideration of pull request
Joseph Hickey, Vantage Systems, Inc.

The following functions have read-only inputs which are passed by
pointer, so it should be "const" qualified:

CFE_ES_CopyToCDS
CFE_SB_TransmitMsg
CFE_SB_TransmitMsgValidate
@jphickey jphickey added the CCB:Ready Ready for discussion at the Configuration Control Board (CCB) label Aug 5, 2021
@jphickey
Copy link
Contributor Author

jphickey commented Aug 5, 2021

This is a simple change, I would vote to include in Caelum - as it corrects the prototype to match the implementation.

Note that implementation did NOT change here, just the prototype (and stub to match).

@skliper skliper added this to the 7.0.0 milestone Aug 5, 2021
@astrogeco astrogeco added CCB:Approved Indicates code review and approval by community CCB and removed CCB:Ready Ready for discussion at the Configuration Control Board (CCB) labels Aug 11, 2021
@astrogeco
Copy link
Contributor

CCB:2021-08-11 APPROVED

@astrogeco astrogeco changed the base branch from main to integration-candidate August 13, 2021 18:43
@astrogeco astrogeco merged commit 14a16e3 into nasa:integration-candidate Aug 13, 2021
astrogeco added a commit to nasa/cFS that referenced this pull request Aug 13, 2021
- Mark read only inputs as const
astrogeco added a commit to nasa/cFS that referenced this pull request Aug 17, 2021
**Combines**

nasa/cFE#1808, v6.8.0-rc1+dev873

**Includes**

- nasa/cFE#1790, Port "CFE_UtAssert_SuccessCheck" and related macros from coverage test to functional test #1784, add CFE assert macros to functional test
- nasa/cFE#1779, Adds invalid id syslog to for CFE_ES_DeleteApp and CFE_ES_ReloadApp and verifies required reporting
- nasa/cFE#1785, Stop memory leak & add cds size test.
- nasa/cFE#1765, Mark read only inputs as const
- nasa/cFE#1804, Check resource ID idx is less than max
- nasa/cFE#1778, Add ES Application Behavior Functional Tests
- nasa/cFE#1801, Update CFE_ES_RunLoop documentation
- nasa/cFE#1745, Add Message Api Functional Test
- nasa/cFE#1798, update in/out status and nonnull/nonzero tags
- nasa/cFE#1783, Add External Time Source Functional Tests
- nasa/cFE#1800, Add Perf API functional tests

Co-authored-by: Jacob Hageman <skliper@users.noreply.github.com>
Co-authored-by: Joseph Hickey <jphickey@users.noreply.github.com>
Co-authored-by: Alex Campbell <zanzaben@users.noreply.github.com>
Co-authored-by: Niall Mullane <nmullane@users.noreply.github.com>
Co-authored-by: Paul <pavll@users.noreply.github.com>
astrogeco added a commit to nasa/cFS that referenced this pull request Aug 17, 2021
**Combines**

nasa/cFE#1808, v6.8.0-rc1+dev873

**Includes**

- nasa/cFE#1790, Port "CFE_UtAssert_SuccessCheck" and related macros from coverage test to functional test #1784, add CFE assert macros to functional test
- nasa/cFE#1779, Adds invalid id syslog to for CFE_ES_DeleteApp and CFE_ES_ReloadApp and verifies required reporting
- nasa/cFE#1785, Stop memory leak & add cds size test.
- nasa/cFE#1765, Mark read only inputs as const
- nasa/cFE#1804, Check resource ID idx is less than max
- nasa/cFE#1778, Add ES Application Behavior Functional Tests
- nasa/cFE#1801, Update CFE_ES_RunLoop documentation
- nasa/cFE#1745, Add Message Api Functional Test
- nasa/cFE#1798, update in/out status and nonnull/nonzero tags
- nasa/cFE#1783, Add External Time Source Functional Tests
- nasa/cFE#1800, Add Perf API functional tests

Co-authored-by: Jacob Hageman <skliper@users.noreply.github.com>
Co-authored-by: Joseph Hickey <jphickey@users.noreply.github.com>
Co-authored-by: Alex Campbell <zanzaben@users.noreply.github.com>
Co-authored-by: Niall Mullane <nmullane@users.noreply.github.com>
Co-authored-by: Paul <pavll@users.noreply.github.com>
@jphickey jphickey deleted the fix-1726-const-correctness branch August 17, 2021 20:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CCB:Approved Indicates code review and approval by community CCB
Projects
None yet
Development

Successfully merging this pull request may close these issues.

DataToCopy argument of CFE_ES_CopyToCDS should be "const"
3 participants