summaryrefslogtreecommitdiff
path: root/ifpps.c
diff options
context:
space:
mode:
authorTobias Klauser <tklauser@distanz.ch>2013-07-10 23:16:23 +0200
committerTobias Klauser <tklauser@distanz.ch>2013-07-10 23:16:23 +0200
commit4f42ef17be2bba0e3ed997d478beb596e5e57e0a (patch)
tree8a4555537905b905bde843f8bb4f2f9c1319ce93 /ifpps.c
parent7ebae5df505c81dcfe61fbe86f2af38adf5b52b0 (diff)
ifpps: Remove unecessary whitespaces in mvwprintw() calls
Remove trailing whitespace where they're not necessary for the background to extend beyond the text. Replace whitespaces needed for tabbing by setting the appropriate format string field width modifiers. Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Diffstat (limited to 'ifpps.c')
-rw-r--r--ifpps.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/ifpps.c b/ifpps.c
index 1242f30..5328b03 100644
--- a/ifpps.c
+++ b/ifpps.c
@@ -780,7 +780,7 @@ static void screen_percpu_states_one(WINDOW *screen, const struct ifstat *rel,
"cpu%*d%s:%s %12.1lf%% usr/t "
"%9.1lf%% sys/t "
"%10.1lf%% idl/t "
- "%11.1lf%% iow/t ", max_padd, idx,
+ "%11.1lf%% iow/t", max_padd, idx,
tag, strlen(tag) == 0 ? " " : "",
100.0 * (rel->cpu_user[idx] + rel->cpu_nice[idx]) / all,
100.0 * rel->cpu_sys[idx] / all,
@@ -818,7 +818,7 @@ static void screen_percpu_states(WINDOW *screen, const struct ifstat *rel,
"avg: %14.1lf%% usr/t "
"%9.1lf%% sys/t "
"%10.1lf%% idl/t "
- "%11.1lf%% iow/t ",
+ "%11.1lf%% iow/t",
100.0 * (avg->cpu_user + avg->cpu_nice) / all,
100.0 * avg->cpu_sys / all,
100.0 * avg->cpu_idle /all,
@@ -831,9 +831,9 @@ static void screen_percpu_irqs_rel_one(WINDOW *screen, const struct ifstat *rel,
int max_padd = padding_from_num(get_number_cpus());
mvwprintw(screen, (*voff)++, 2,
- "cpu%*d%s:%s %13llu irqs/t "
- "%15llu sirq rx/t "
- "%15llu sirq tx/t ", max_padd, idx,
+ "cpu%*d%s:%s %13llu irqs/t "
+ "%17llu sirq rx/t "
+ "%17llu sirq tx/t", max_padd, idx,
tag, strlen(tag) == 0 ? " " : "",
rel->irqs[idx],
rel->irqs_srx[idx],
@@ -859,9 +859,9 @@ static void screen_percpu_irqs_rel(WINDOW *screen, const struct ifstat *rel,
screen_percpu_irqs_rel_one(screen, rel, voff, cpu_hits[cpus - 1].idx, "-");
mvwprintw(screen, (*voff)++, 2,
- "avg: %15.2Lf irqs/t "
- "%16.2Lf sirq rx/t "
- "%15.2Lf sirq tx/t ",
+ "avg: %15.2Lf irqs/t "
+ "%17.2Lf sirq rx/t "
+ "%17.2Lf sirq tx/t",
avg->irqs_rel, avg->irqs_srx_rel, avg->irqs_stx_rel);
}