Fix #1667, CFE_SB_MsgHdrSize returns size_t #1674
Fix #1667, CFE_SB_MsgHdrSize returns size_t #1674astrogeco merged 2 commits intonasa:integration-candidatefrom oliverhamburger:fix-1667-CFE-SB-MsgHdrSize-returns-size-t-but-still-attempts-to-return-CFE-status-code
Conversation
…urn CFE status code
jphickey
left a comment
There was a problem hiding this comment.
Just a minor recommendation - when documenting return values, the \returns tag should be just a generic description, and the \retval tag should be used for documenting specific values.
So, I'd recommend something like:
\returns Estimated number of bytes in the message header for the given message
\retval 0 if an error occurs, such as if the MsgPtr argument is not valid or header type cannot be identified
(Also to be pedantic, it is MsgPtr that is checked for NULL, not *MsgPtr)
jphickey
left a comment
There was a problem hiding this comment.
Looks good. I would only recommend a "squash commit" now to consolidate the 3 commits into one on this branch. But otherwise looks good.
…urn CFE status code
nasa/cFE#1670, Update API doxygen list nasa/cFE#1671, update documentation for CFE_ES_GetPoolBufInfo nasa/cFE#1674, CFE_SB_MsgHdrSize returns size_t nasa/osal#1106, Add independent OS_rename functional test parameter checks
**Combines** nasa/cFE#1665, v6.8.0-rc1+dev762 nasa/osal#1113, v5.1.0-rc1+dev573 **Includes** nasa/cFE#1664, remove default .dat extension nasa/cFE#1660, Change CI to use Test Log. nasa/cFE#1670, Update API doxygen list nasa/cFE#1671, update documentation for CFE_ES_GetPoolBufInfo nasa/cFE#1674, CFE_SB_MsgHdrSize returns size_t nasa/cFE#1668, improve SB coverage test nasa/cFE#1694, correct function name in UT_BSP_Unlock nasa/osal#1106, Add independent OS_rename functional test parameter checks Co-authored-by: Jacob Hageman <[email protected]> Co-authored-by: Joseph Hickey <[email protected]> Co-authored-by: Alex Campbell <[email protected]> Co-authored-by: Oliver Hamburger <[email protected]>
|
@oliverhamburger can you fill out a CLA? We are trying to submit an NTR for the Draco development cycle. |
CLA sent to [email protected] |
Describe the contribution
Fixes Issue #1667 by changing the return type in CFE_SB_MsgHdrSize and CFE_SB_GetUserDataLength
Testing performed
Build and ran unit tests
Expected behavior changes
CFE_SB_MsgHdrSize and CFE_SB_GetUserDataLength now return 0 when *MsgPtr is NULL
System(s) tested on
Ubuntu 20.04
Additional context
Add any other context about the contribution here.
Contributor Info
Oliver Hamburger GSFC