Skip to content

Commit 5d944c6

Browse files
committed
Revert "Fix empty for loop body"
This reverts commit d2a9b54. The empty for loop was working as intended.
1 parent d2a9b54 commit 5d944c6

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/conf.c

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -863,13 +863,13 @@ void parse_trusted_mac_list(const char *ptr) {
863863
config.trustedmaclist->next = NULL;
864864
} else {
865865
/* Advance to the last entry */
866-
for (p = config.trustedmaclist; p->next != NULL; p = p->next) {
867-
p->next = safe_malloc(sizeof(t_trusted_mac));
868-
p = p->next;
869-
p->mac = safe_strdup(mac);
870-
p->next = NULL;
871-
}
866+
for (p = config.trustedmaclist; p->next != NULL; p = p->next);
867+
p->next = safe_malloc(sizeof(t_trusted_mac));
868+
p = p->next;
869+
p->mac = safe_strdup(mac);
870+
p->next = NULL;
872871
}
872+
}
873873
}
874874
}
875875

0 commit comments

Comments
 (0)