File qdiskd_fix_bad_timer_check.patch of Package cluster
commit 4fe4dbb1e1261b2cfa471840134f27043f683385
Author: Lon Hohberger <lhh@redhat.com>
Date: Thu Mar 3 17:39:10 2011 -0500
qdiskd: Fix bad timer check
Resolves: rhbz#679274
Resolves: rhbz#688154
Signed-off-by: Lon Hohberger <lhh@redhat.com>
Tested-by: Masanari Iida <masanari_iida@hp.com>
Acked-by: Fabio M. Di Nitto <fdinitto@redhat.com>
diff --git a/cman/qdisk/score.c b/cman/qdisk/score.c
index 572464d..3ca531f 100644
--- a/cman/qdisk/score.c
+++ b/cman/qdisk/score.c
@@ -86,7 +86,8 @@ fork_heuristic(struct h_data *h, struct timespec *now)
}
if (now->tv_sec < h->nextrun.tv_sec ||
- now->tv_nsec < h->nextrun.tv_nsec)
+ ((now->tv_sec == h->nextrun.tv_sec) &&
+ (now->tv_nsec < h->nextrun.tv_nsec)))
return 0;
h->nextrun.tv_sec = now->tv_sec + h->interval;