From b93c182ff357b0a6142e4b27e4e40a18cabfb45b Mon Sep 17 00:00:00 2001 From: Niels Provos Date: Thu, 30 Oct 2008 19:40:35 +0000 Subject: [PATCH] from trunk: clear the timer cache on entering event loop; reported by Victor Chang svn:r945 --- ChangeLog | 1 + event.c | 3 +++ 2 files changed, 4 insertions(+) diff --git a/ChangeLog b/ChangeLog index ae5d991e..78649137 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,6 @@ Changes in 1.4.9-stable: o event_add would not return error for some backends; from Dean McNamee + o Clear the timer cache on entering the event loop; reported by Victor Chang Changes in 1.4.8-stable: o Match the query in DNS replies to the query in the request; from Vsevolod Stakhov. diff --git a/event.c b/event.c index 487ce252..e94173ab 100644 --- a/event.c +++ b/event.c @@ -472,6 +472,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;