]> git.ipfire.org Git - thirdparty/bird.git/commitdiff
Fixes bug on Linux 2.4.x - kernel sync does not work until restart of kernel protocol.
authorOndrej Zajicek <santiago@crfreenet.org>
Fri, 21 May 2010 09:51:39 +0000 (11:51 +0200)
committerOndrej Zajicek <santiago@crfreenet.org>
Fri, 21 May 2010 10:00:53 +0000 (12:00 +0200)
Which was, actually, a bug in timers - on older kernel, monotonic timer
is missing and the other implementation started with now == 0, which
collides with usage 0 as a special value in timer->expires field.

sysdep/unix/io.c

index 456644b2b21e93a1a176d1997550c601492d2a3d..8058fa66515cb214aede0dfe7c4d85865a30043f 100644 (file)
@@ -117,7 +117,8 @@ tracked_fopen(pool *p, char *name, char *mode)
 static list near_timers, far_timers;
 static bird_clock_t first_far_timer = TIME_INFINITY;
 
-bird_clock_t now, now_real;
+/* now must be different from 0, because 0 is a special value in timer->expires */
+bird_clock_t now = 1, now_real;
 
 static void
 update_times_plain(void)