canbusload: redraw mode: use less screen estate
Use less screen estate by not printing unneeded newlines in redraw mode.pull/461/head
parent
92adbda471
commit
84919edbaa
|
|
@ -223,6 +223,7 @@ void printstats(int signo)
|
||||||
if (color)
|
if (color)
|
||||||
printf("%s", ATTRESET);
|
printf("%s", ATTRESET);
|
||||||
|
|
||||||
|
if (!redraw || (i < currmax - 1))
|
||||||
printf("\n");
|
printf("\n");
|
||||||
|
|
||||||
stat[i].recv_frames = 0;
|
stat[i].recv_frames = 0;
|
||||||
|
|
@ -231,7 +232,9 @@ void printstats(int signo)
|
||||||
stat[i].recv_bits_payload = 0;
|
stat[i].recv_bits_payload = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!redraw)
|
||||||
printf("\n");
|
printf("\n");
|
||||||
|
|
||||||
fflush(stdout);
|
fflush(stdout);
|
||||||
|
|
||||||
alarm(1);
|
alarm(1);
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue