From d26cd43b41138c4cbe29f0be9b9dc020520b6375 Mon Sep 17 00:00:00 2001 From: Florian Forster Date: Thu, 20 Nov 2014 14:46:40 +0100 Subject: [PATCH] src/oping.c: Fix status output. This is a really dirty hack: If the percentile and/or median output decreases, the output may have less characters than previously. Add spaces at the end of the string to clear digits with may have been there, to avoid the "maximum" value be appear to go through the roof. --- src/oping.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/oping.c b/src/oping.c index debe237..e6be877 100644 --- a/src/oping.c +++ b/src/oping.c @@ -1219,7 +1219,7 @@ static int update_stats_from_context (ping_context_t *ctx, pingobj_iter_t *iter) percentile = percentile_to_latency (ctx, opt_percentile); mvwprintw (ctx->window, /* y = */ 2, /* x = */ 2, - "RTT[ms]: min = %.0f, median = %.0f, p(%.0f) = %.0f, max = %.0f", + "RTT[ms]: min = %.0f, median = %.0f, p(%.0f) = %.0f, max = %.0f ", min, median, opt_percentile, percentile, max); } -- 2.11.0