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 #28: Check return of CFE_TBL_GetAddress #29

Merged
merged 1 commit into from
Dec 30, 2019

Conversation

jphickey
Copy link
Contributor

@jphickey jphickey commented Dec 6, 2019

Describe the contribution

Fix #28.

The code must not dereference the pointer unless the call returned CFE_SUCCESS, otherwise the pointer is not valid.

Testing performed
Execute CFE under simulation, send ProcessCC command and ensure no change to nominal behavior

Expected behavior changes
No change in the nominal case, where the command operates normally and the table address is valid.

The SAMPLE_ProcessCC function now does not dereference the table pointer in case the CFE_TBL_GetAddress function fails, which is confirmed in the unit test.

System(s) tested on:
Ubuntu 18.04 LTS, 64-bit

Contributor Info
Joseph Hickey, Vantage Systems, Inc.

Community contributors
You must attach a signed CLA (required for acceptance) or reference one already submitted

The code must not dereference the pointer unless the call
returned CFE_SUCCESS, otherwise the pointer is not valid.
@skliper skliper added this to the 1.2.0 milestone Dec 18, 2019
@skliper skliper added the CCB:Approved Indicates code approval by CCB label Dec 18, 2019
@skliper
Copy link
Contributor

skliper commented Dec 18, 2019

CCB 20191218 - Reviewed and approved for IC

@skliper skliper changed the base branch from master to merge-20191230 December 30, 2019 16:47
@skliper skliper merged commit 693d75f into merge-20191230 Dec 30, 2019
skliper added a commit that referenced this pull request Dec 30, 2019
Fix #23, #25, #28, #30
Reviewed and approved at 2019-12-18 CCB
@skliper skliper deleted the fix-28-check-tbl-address branch December 30, 2019 18:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
CCB:Approved Indicates code approval by CCB
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants