summaryrefslogtreecommitdiff
path: root/sysdep/unix
diff options
context:
space:
mode:
authorOndrej Zajicek <santiago@crfreenet.org>2022-06-04 17:54:08 +0200
committerOndrej Zajicek <santiago@crfreenet.org>2022-06-04 17:54:08 +0200
commitf39e9aa20363eccc38289958f23c789d037c269b (patch)
treef46c5afb289f28bad85995a9d217214c5121bd96 /sysdep/unix
parenta8a3d95be5db1a8a7d5a17e2eb8e233417b1d8c7 (diff)
IO: Improve resolution of latency debugging messages
Diffstat (limited to 'sysdep/unix')
-rw-r--r--sysdep/unix/io.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sysdep/unix/io.c b/sysdep/unix/io.c
index 4fd77453..17dc05a3 100644
--- a/sysdep/unix/io.c
+++ b/sysdep/unix/io.c
@@ -2046,8 +2046,8 @@ io_update_time(void)
event_open->duration = last_time - event_open->timestamp;
if (event_open->duration > config->latency_limit)
- log(L_WARN "Event 0x%p 0x%p took %d ms",
- event_open->hook, event_open->data, (int) (event_open->duration TO_MS));
+ log(L_WARN "Event 0x%p 0x%p took %u.%03u ms",
+ event_open->hook, event_open->data, (uint) (event_open->duration TO_MS), (uint) (event_open->duration % 1000));
event_open = NULL;
}
@@ -2151,8 +2151,8 @@ watchdog_stop(void)
btime duration = last_time - loop_time;
if (duration > config->watchdog_warning)
- log(L_WARN "I/O loop cycle took %d ms for %d events",
- (int) (duration TO_MS), event_log_num);
+ log(L_WARN "I/O loop cycle took %u.%03u ms for %d events",
+ (uint) (duration TO_MS), (uint) (duration % 1000), event_log_num);
}