From 31cfe52662fe14c24f0b6794fe2e16cc3aac0696 Mon Sep 17 00:00:00 2001 From: Niels Provos Date: Thu, 30 Oct 2008 19:38:31 +0000 Subject: [PATCH] clear the timer cache on entering event loop; reported by Victor Chang svn:r944 --- ChangeLog | 1 + event.c | 3 +++ 2 files changed, 4 insertions(+) diff --git a/ChangeLog b/ChangeLog index 96c34bbf..fbe24670 100644 --- a/ChangeLog +++ b/ChangeLog @@ -125,6 +125,7 @@ Changes in current version: o Match the query in DNS replies to the query in the request; from Vsevolod Stakhov. o Add new utility functions to correctly observe and log winsock errors. o Do not remove Accept-Encoding header + o Clear the timer cache on entering the event loop; reported by Victor Chang Changes in 1.4.0: o allow \r or \n individually to separate HTTP headers instead of the standard "\r\n"; from Charles Kerr. diff --git a/event.c b/event.c index 6034ef36..1ee3df5d 100644 --- a/event.c +++ b/event.c @@ -695,6 +695,9 @@ event_base_loop(struct event_base *base, int flags) struct timeval *tv_p; int res, done; + /* clear time cache */ + base->tv_cache.tv_sec = 0; + if (&base->sig.ev_signal_added) evsignal_base = base; done = 0; -- 2.49.0