Bugfix/fix splint warnings (#250)
* Fix SPLINT to perform static defect analysis Fix the SPLINT invocation in Makefile Fix C files where SPLINT detected problems. Remove UCIX check from SPLINT Use SPLINT friendly parsing code disable for bacsec Co-authored-by: Steve Karg <skarg@users.sourceforge.net>
This commit is contained in:
@@ -181,18 +181,19 @@ static bool bbmd6_add_vmac(uint32_t device_id, BACNET_IP6_ADDRESS *addr)
|
||||
bool status = false;
|
||||
struct vmac_data *vmac;
|
||||
struct vmac_data new_vmac;
|
||||
unsigned i = 0;
|
||||
|
||||
if (addr) {
|
||||
vmac = VMAC_Find_By_Key(device_id);
|
||||
if (vmac) {
|
||||
/* already exists - replace? */
|
||||
PRINTF("VMAC existing %u [", (unsigned int)device_id);
|
||||
for (unsigned i = 0; i < vmac->mac_len; i++) {
|
||||
for (i = 0; i < vmac->mac_len; i++) {
|
||||
PRINTF("%02X", vmac->mac[i]);
|
||||
}
|
||||
PRINTF("]\n");
|
||||
PRINTF("VMAC ignoring %u [", (unsigned int)device_id);
|
||||
for (unsigned i = 0; i < IP6_ADDRESS_MAX; i++) {
|
||||
for (i = 0; i < IP6_ADDRESS_MAX; i++) {
|
||||
PRINTF("%02X", addr->address[i]);
|
||||
}
|
||||
PRINTF("%04X", addr->port);
|
||||
|
||||
@@ -258,6 +258,7 @@ void VMAC_Cleanup(void)
|
||||
struct vmac_data *pVMAC;
|
||||
uint32_t device_id;
|
||||
const int index = 0;
|
||||
unsigned i = 0;
|
||||
|
||||
if (VMAC_List) {
|
||||
do {
|
||||
@@ -266,7 +267,7 @@ void VMAC_Cleanup(void)
|
||||
if (pVMAC) {
|
||||
PRINTF("VMAC List: %lu [", (unsigned long)device_id);
|
||||
/* print the MAC */
|
||||
for (unsigned i = 0; i < pVMAC->mac_len; i++) {
|
||||
for (i = 0; i < pVMAC->mac_len; i++) {
|
||||
PRINTF("%02X", pVMAC->mac[i]);
|
||||
}
|
||||
PRINTF("]\n");
|
||||
|
||||
Reference in New Issue
Block a user