dcavalca / rpms / systemd

Forked from rpms/systemd 3 months ago
Clone
Blob Blame History Raw
From fdb14b7ef40d1f19f3bd7c8fa2a3821c2be87a5e Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= <zbyszek@in.waw.pl>
Date: Wed, 1 Oct 2014 07:34:05 -0500
Subject: [PATCH] core: limit timestamp to sane precision

Anything below .1 s is meaningless anyway.
---
 src/core/main.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/core/main.c b/src/core/main.c
index 64c2b3f3a1..1a62e04c80 100644
--- a/src/core/main.c
+++ b/src/core/main.c
@@ -1725,7 +1725,7 @@ int main(int argc, char *argv[]) {
                 after_startup = now(CLOCK_MONOTONIC);
                 log_full(arg_action == ACTION_TEST ? LOG_INFO : LOG_DEBUG,
                          "Loaded units and determined initial transaction in %s.",
-                         format_timespan(timespan, sizeof(timespan), after_startup - before_startup, 0));
+                         format_timespan(timespan, sizeof(timespan), after_startup - before_startup, 100 * USEC_PER_MSEC));
 
                 if (arg_action == ACTION_TEST) {
                         printf("-> By jobs:\n");