void openlogger(const char *ident, logmode_t mode) {
logident = ident;
logmode = mode;
-
+
switch(mode) {
case LOGMODE_STDERR:
logpid = getpid();
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;