From 15dacfec6f25fe291ce8aaa702c7fabbee9e3d00 Mon Sep 17 00:00:00 2001 From: Jan-Erik Rediger Date: Wed, 13 Jan 2016 10:22:29 -0700 Subject: [PATCH] Fix nanosecond conversion 1 microsecond = 1000 nanoseconds 1e3 = 1000 10e3 = 10000 --- src/redis-cli.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/redis-cli.c b/src/redis-cli.c index f70c05846..d7f250fd1 100644 --- a/src/redis-cli.c +++ b/src/redis-cli.c @@ -2331,7 +2331,7 @@ static void intrinsicLatencyMode(void) { } double avg_us = (double)run_time/runs; - double avg_ns = avg_us * 10e3; + double avg_ns = avg_us * 1e3; if (force_cancel_loop || end > test_end) { printf("\n%lld total runs " "(avg latency: "