X-Git-Url: https://www.tinc-vpn.org/git/browse?p=tinc;a=blobdiff_plain;f=src%2Fnet.c;h=1de5f1fb711530eff4420f212062ef26424e06bc;hp=9e4829a35b75fcefba7eaaab3d044db8c2071d00;hb=116065afe352221ac6c2c8e34c109252004d6a59;hpb=a39a9506cd041a7092a98498b362eaacfd2f33c3 diff --git a/src/net.c b/src/net.c index 9e4829a3..1de5f1fb 100644 --- a/src/net.c +++ b/src/net.c @@ -423,18 +423,17 @@ int main_loop(void) } } + if(sigalrm) { + logger(LOG_INFO, _("Flushing event queue")); + expire_events(); + sigalrm = false; + } while((event = get_expired_event())) { event->handler(event->data); free_event(event); } - if(sigalrm) { - logger(LOG_INFO, _("Flushing event queue")); - flush_events(); - sigalrm = false; - } - if(sighup) { connection_t *c; avl_node_t *node;