Bugfix/clang tidy applied 2022 (#232)

* clang-tidy applied fixes to src folder
* clang-tidy applied fixes to apps folder

Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
This commit is contained in:
Steve Karg
2022-02-27 19:14:17 -06:00
committed by GitHub
parent 5e70eeecfc
commit d0fe77c030
33 changed files with 211 additions and 123 deletions
+4 -2
View File
@@ -566,9 +566,10 @@ bool parse_cmd(int argc, char *argv[])
current->params.mstp_params.max_master =
(uint8_t)atoi(argv[optind]);
if (current->params.mstp_params.max_master <
current->route_info.mac[0])
current->route_info.mac[0]) {
current->params.mstp_params.max_master =
current->route_info.mac[0];
}
if (argv[optind + 1][0] != '-') {
current->params.mstp_params.max_frames =
@@ -778,8 +779,9 @@ uint16_t process_msg(BACMSG *msg, MSG_DATA *data, uint8_t **buff)
/* if received from another router save real source address (not other
* router source address) */
if (addr.net > 0 && addr.net < BACNET_BROADCAST_NETWORK &&
data->src.net != addr.net)
data->src.net != addr.net) {
memmove(&data->src, &addr, sizeof(BACNET_ADDRESS));
}
/* encode both source and destination for broadcast and router-to-router
* communication */