chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
dbus: properly serialize calendar timer data
[elogind.git]
/
src
/
core
/
timer.c
diff --git
a/src/core/timer.c
b/src/core/timer.c
index 31ef176e7e3d750c8867bc94d96d32063494262c..4453aa0781f5ef64bf14e9609959c7a091688d7a 100644
(file)
--- a/
src/core/timer.c
+++ b/
src/core/timer.c
@@
-323,7
+323,7
@@
static void timer_enter_waiting(Timer *t, bool initial) {
log_debug_unit(UNIT(t)->id,
"%s: Monotonic timer elapses in %s the next time.",
UNIT(t)->id,
log_debug_unit(UNIT(t)->id,
"%s: Monotonic timer elapses in %s the next time.",
UNIT(t)->id,
- format_timespan(buf, sizeof(buf), t->next_elapse_monotonic
- ts.monotonic
));
+ format_timespan(buf, sizeof(buf), t->next_elapse_monotonic
> ts.monotonic ? t->next_elapse_monotonic - ts.monotonic : 0
));
r = unit_watch_timer(UNIT(t), CLOCK_MONOTONIC, false, t->next_elapse_monotonic, &t->monotonic_watch);
if (r < 0)
r = unit_watch_timer(UNIT(t), CLOCK_MONOTONIC, false, t->next_elapse_monotonic, &t->monotonic_watch);
if (r < 0)