-
-
Notifications
You must be signed in to change notification settings - Fork 209
check port id range #251
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
check port id range #251
Conversation
libcanard/canard.c
Outdated
| #define CRC_INITIAL 0xFFFFU | ||
| #define CRC_RESIDUE 0x0000U | ||
| #define CRC_SIZE_BYTES 2U | ||
| #define PORT_ID_MINIMUM 49152 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what's this for?
libcanard/canard.c
Outdated
| (((transfer_kind == CanardTransferKindMessage) && (port_id <= CANARD_SUBJECT_ID_MAX)) || | ||
| (port_id <= CANARD_SERVICE_ID_MAX))) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please extract these into a port_id_ok variable to enhance readability, and remove the extra blank line.
|



closes #221