From 7cbcdfee4e2f8088487d3bd276afc797d6d70eaa Mon Sep 17 00:00:00 2001 From: onefang Date: Wed, 11 Aug 2021 19:31:59 +1000 Subject: More betterer output. --- src/sledjchisl/sledjchisl.c | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) (limited to 'src/sledjchisl') diff --git a/src/sledjchisl/sledjchisl.c b/src/sledjchisl/sledjchisl.c index 05e35a9..f04d5ff 100644 --- a/src/sledjchisl/sledjchisl.c +++ b/src/sledjchisl/sledjchisl.c @@ -8292,6 +8292,14 @@ sendReply: fcgiDone: FCGI_Finish(); + + struct timespec now; + if (-1 == clock_gettime(CLOCK_REALTIME, &now)) + perror_msg("Unable to get the time."); + double n = (now.tv_sec * 1000000000.0) + now.tv_nsec; + double t = (Rd->then.tv_sec * 1000000000.0) + Rd->then.tv_nsec; + T("Finished web request, took %lf seconds for %s %s://%s%s -> %s%s", (n - t) / 1000000000.0, Rd->Method, Rd->Scheme, Rd->Host, Rd->RUri, webRoot, Rd->Path); + if (NULL != Rd->outQuery) free(Rd->outQuery); if (NULL != Rd->shs.name) free(Rd->shs.name); Rd->shs.name = NULL; @@ -8312,12 +8320,6 @@ fcgiDone: if (Rd->lnk) free(Rd->lnk); free(Rd->RUri); - struct timespec now; - if (-1 == clock_gettime(CLOCK_REALTIME, &now)) - perror_msg("Unable to get the time."); - double n = (now.tv_sec * 1000000000.0) + now.tv_nsec; - double t = (Rd->then.tv_sec * 1000000000.0) + Rd->then.tv_nsec; - I("Finished web request, took %lf seconds", (n - t) / 1000000000.0); free(Rd); } -- cgit v1.1