-
Notifications
You must be signed in to change notification settings - Fork 235
Description
Is your feature request related to a problem? Please describe.
For Message ID's, cFS generally use 0x%08X but sometimes it's printed with 0x%08x (lowercase a-f), or without the 0x, or even as %d or %u. (Although I don't know if that's used anymore.)
Describe the solution you'd like
Per https://en.wikipedia.org/wiki/C_data_types#Printf_and_scanf_format_specifiers C99 added printf format string macros for int types and it would be keen to follow this practice. I suggest PRIxMSG or PRIdMSG for printing (generally, sending an event message) a message ID in hex or decimal (defined as "0x%08X" and "%u" for unsigned integer (32-bit) MsgIds. So instead of:
...SendEvent(..."Error: unable to process message (MsgId=0x%08X)", MsgId)
it would be:
...SendEvent(..."Error: unable to process message (MsgId=" PRIxMSG ")", MsgId)
Describe alternatives you've considered
Leave well enough alone...:D
Additional context
Add any other context about the feature request here.
Requester Info
[email protected]