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

CF test incorrect initialization of "dummy_channel" pipe ID #48

Closed
jphickey opened this issue Nov 23, 2021 · 0 comments · Fixed by #78
Closed

CF test incorrect initialization of "dummy_channel" pipe ID #48

jphickey opened this issue Nov 23, 2021 · 0 comments · Fixed by #78
Milestone

Comments

@jphickey
Copy link
Contributor

This issue was imported from the GSFC issue tracking system

Imported from: [GSFCCFS-1784] CF test incorrect initialization of "dummy_channel" pipe ID
Originally submitted by: Hickey, Joseph P. (GSFC-582.0)[VANTAGE SYSTEMS INC] on Tue Nov 16 17:22:51 2021

Original Description:
These three tests utilize a "dummy_channel" structure:

  1. Test_CF_CFDP_DisableEngine_ClosesAllActiveFilesAndNoOpenPlaybackDirectoriesResetsAllQueueCountersDeletesPipe
  2. Test_CF_CFDP_DisableEngine_ClosesAllActiveFilesAndAnyOpenPlaybackDirectoriesResetsAllQueueCountersDeletesPipe
  3. Test_CF_CFDP_DisableEngine_ClosesAllActiveFilesAndAllOpenPlaybackDirectoriesResetsAllQueueCountersDeletesPipe

These are calling Any_uint8() and assigning that value to to the pipe member of the structure. However on Caelum the Pipe IDs are actually 32 bits like other IDs (not 8) and when using strict ID types, this assignment will (correctly) fail with a compiler error as being invalid.

The test needs to be explicit that it is intentionally using an integer as a made-up PipeID and needs to use the conversion macro do to so.

jphickey added a commit to jphickey/CF that referenced this issue Nov 23, 2021
Correct the pipe ID assignment in UT to use the resourceID type.

This also uses a fixed/consistent value here, rather than a random
value.  There is no real need to use a random value.
jphickey added a commit to jphickey/CF that referenced this issue Dec 1, 2021
Correct the pipe ID assignment in UT to use the resourceID type.

This also uses a fixed/consistent value here, rather than a random
value.  There is no real need to use a random value.
astrogeco added a commit that referenced this issue Dec 8, 2021
Fix #48, use proper CFE_SB_PipeID type
@skliper skliper added this to the Draco milestone Jan 7, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants