aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/pluto/kernel.c2
-rw-r--r--src/pluto/state.c2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/pluto/kernel.c b/src/pluto/kernel.c
index 5a4850155..0d8f3ba3f 100644
--- a/src/pluto/kernel.c
+++ b/src/pluto/kernel.c
@@ -2643,7 +2643,7 @@ bool was_eroute_idle(struct state *st, time_t idle_max, time_t *idle_time)
if (get_sa_info(st, TRUE, &bytes, &use_time) && use_time != UNDEFINED_TIME)
{
- *idle_time = time(NULL) - use_time;
+ *idle_time = time_monotonic(NULL) - use_time;
ret = *idle_time >= idle_max;
}
diff --git a/src/pluto/state.c b/src/pluto/state.c
index 51f444deb..a07ae6a60 100644
--- a/src/pluto/state.c
+++ b/src/pluto/state.c
@@ -782,7 +782,7 @@ void fmt_state(bool all, struct state *st, time_t n, char *state_buf,
}
if (st->st_esp.present)
{
- time_t now = time(NULL);
+ time_t now = time_monotonic(NULL);
add_said(&c->spd.that.host_addr, st->st_esp.attrs.spi, SA_ESP);
add_sa_info(st, FALSE);