-
Notifications
You must be signed in to change notification settings - Fork 236
Description
Describe the bug
Given max number of message keys is 1+ highest valid msgid:
cFE/fsw/cfe-core/src/sb/cfe_sb_priv.h
Line 107 in 95f34d2
| #define CFE_SB_MAX_NUMBER_OF_MSG_KEYS (1+CFE_PLATFORM_SB_HIGHEST_VALID_MSGID) |
and message key is uint16:
cFE/fsw/cfe-core/src/sb/cfe_sb_priv.h
Line 122 in 95f34d2
| typedef uint16 CFE_SB_MsgKey_Atom_t; |
Setting CFE_PLATFORM_SB_HIGHEST_VALID_MSGID to 0xFFFF results in forever loop in:
cFE/fsw/cfe-core/src/sb/cfe_sb_init.c
Lines 219 to 224 in 95f34d2
| CFE_SB_MsgKey_Atom_t KeyVal; | |
| for (KeyVal=0; KeyVal < CFE_SB_MAX_NUMBER_OF_MSG_KEYS; KeyVal++) | |
| { | |
| CFE_SB.MsgMap[KeyVal] = CFE_SB_INVALID_ROUTE_IDX; | |
| } |
To Reproduce
Set CFE_PLATFORM_SB_HIGHEST_VALID_MSGID to 0xFFFF and build/run.
Expected behavior
Full 16 bits of message id should be usable.
Code snips
See above
System observed on:
- Hardware: cFS Dev 3
- OS: Ubuntu 18.04
- Versions: master bundle
Additional context
None
Reporter Info
Jacob Hageman - NASA/GSFC (per JSC identification of the issue)