summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRichard Braun <rbraun@sceen.net>2013-04-06 18:15:21 +0200
committerRichard Braun <rbraun@sceen.net>2013-04-06 18:15:21 +0200
commit806b9d586873b1815887946c6b8a0aae1fe267b8 (patch)
tree1f07d301b31485c858c7792cd75a8635d52c9bad
parent0992a61cafb0f3def3b6997f7c3670a4474f479b (diff)
pfinet: fix timeout evaluation
* pfinet/timer-emul.c (timer_function): Fix comparison between expire time and jiffies.
-rw-r--r--pfinet/timer-emul.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/pfinet/timer-emul.c b/pfinet/timer-emul.c
index 5a503597..f6760d7e 100644
--- a/pfinet/timer-emul.c
+++ b/pfinet/timer-emul.c
@@ -51,7 +51,7 @@ timer_function (void *this_is_a_pointless_variable_with_a_rather_long_name)
if (!timers)
wait = -1;
- else if (timers->expires < jiff)
+ else if (timers->expires <= jiff)
wait = 0;
else
wait = ((timers->expires - jiff) * 1000) / HZ;
@@ -64,7 +64,7 @@ timer_function (void *this_is_a_pointless_variable_with_a_rather_long_name)
pthread_mutex_lock (&global_lock);
- while (timers->expires < jiffies)
+ while (timers->expires <= jiffies)
{
struct timer_list *tp;