From 39a268b86762c88ba660af4ab9291d38413c83ea Mon Sep 17 00:00:00 2001 From: Martin Willi Date: Tue, 20 Mar 2007 12:29:42 +0000 Subject: [PATCH] fixed CHILD_SA rekeying time in statusall --- src/charon/sa/child_sa.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/charon/sa/child_sa.c b/src/charon/sa/child_sa.c index ba9520cd8..ea7590ceb 100644 --- a/src/charon/sa/child_sa.c +++ b/src/charon/sa/child_sa.c @@ -753,7 +753,7 @@ static int print(FILE *stream, const struct printf_info *info, return fprintf(stream, "(null)"); } - now = (u_int32_t)time(NULL); + now = time(NULL); written += fprintf(stream, "%12s{%d}: %N, %N", this->policy->get_name(this->policy), this->reqid, @@ -796,7 +796,7 @@ static int print(FILE *stream, const struct printf_info *info, /* calculate rekey times */ if (soft) { - rekeying = soft - (now - this->install_time); + rekeying = this->install_time + soft - now; written += fprintf(stream, "in %ds", rekeying); } else