X-Git-Url: https://tinc-vpn.org/git/browse?p=tinc;a=blobdiff_plain;f=src%2Flogger.c;h=184ba35940c7eebdfd6c9577f3c676fea583fd2f;hp=5de88bdeb5a9321eb09bd3182904de80ec54f0a3;hb=0b8b23e0dd7219344543f135ca0aeba8a4a42d48;hpb=ff306f0cdaedb50de1472e7c1fb55de922a6ca60 diff --git a/src/logger.c b/src/logger.c index 5de88bde..184ba359 100644 --- a/src/logger.c +++ b/src/logger.c @@ -140,9 +140,7 @@ void logger(int level, int priority, const char *format, ...) { if(logcontrol) { suppress = true; logcontrol = false; - for(list_node_t *node = connection_list->head, *next; node; node = next) { - next = node->next; - connection_t *c = node->data; + for list_each(connection_t, c, connection_list) { if(!c->status.log) continue; logcontrol = true;