]> granicus.if.org Git - libevent/commitdiff
clear the timer cache on entering event loop; reported by Victor Chang
authorNiels Provos <provos@gmail.com>
Thu, 30 Oct 2008 19:38:31 +0000 (19:38 +0000)
committerNiels Provos <provos@gmail.com>
Thu, 30 Oct 2008 19:38:31 +0000 (19:38 +0000)
svn:r944

ChangeLog
event.c

index 96c34bbf94bb1d108a15ef3499aa6f31f041aabe..fbe24670aced737d9a7acea4a8ad6454a1013385 100644 (file)
--- 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 6034ef3650c0a2d511f99e78937652808292faa9..1ee3df5d0061a85c2a7ee1e833660a7272a5ca19 100644 (file)
--- 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;