From: Hattink, Tjalling (FINT) Date: Tue, 26 Jan 2010 16:11:33 +0000 (+0100) Subject: Fix scheduler to allow stepping clock from timeout handler X-Git-Tag: 1.24~10 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=27a9b0e7b1b07d09f5cc9f6f23b46e4acbdca5b6;p=thirdparty%2Fchrony.git Fix scheduler to allow stepping clock from timeout handler --- diff --git a/sched.c b/sched.c index 38f5e2ea..6412f0a4 100644 --- a/sched.c +++ b/sched.c @@ -440,7 +440,7 @@ dispatch_timeouts(struct timeval *now) { TimerQueueEntry *ptr; int n_done = 0; - while ((n_timer_queue_entries > 0) && + if ((n_timer_queue_entries > 0) && (UTI_CompareTimevals(now, &(timer_queue.next->tv)) >= 0)) { ptr = timer_queue.next;