Describe the bug
In some functions, e.g. CF_WriteQueueDataToFile, CF_WriteHistoryQueueDataToFile, the OSAL file descriptor is being passed as an int32. This is incorrect, but allowed by the backward-compatibility features in OSAL. In a future version, this will become an error.
To Reproduce
Build OSAL with type-safe ID. Implicit conversion of ID to/from an integer will fail to compile.
Expected behavior
Use osal_id_t type instead, which is the correct type for an OSAL ID.
Describe the bug In some functions, e.g. CF_WriteQueueDataToFile, CF_WriteHistoryQueueDataToFile, the OSAL file descriptor is being passed as an
int32
. This is incorrect, but allowed by the backward-compatibility features in OSAL. In a future version, this will become an error.To Reproduce Build OSAL with type-safe ID. Implicit conversion of ID to/from an integer will fail to compile.
Expected behavior Use
osal_id_t
type instead, which is the correct type for an OSAL ID.Code snips https://github.com/nasa/CF/blob/d3ae3f9595033c7c4af4faffc4c4513c1a4b1aa5/fsw/src/cf_utils.h#L224 https://github.com/nasa/CF/blob/d3ae3f9595033c7c4af4faffc4c4513c1a4b1aa5/fsw/src/cf_utils.h#L239
System observed on: Ubuntu 21.10
Reporter Info Joseph Hickey, Vantage Systems, Inc.