diff options
author | jhb <jhb@FreeBSD.org> | 2009-08-19 15:17:13 +0000 |
---|---|---|
committer | jhb <jhb@FreeBSD.org> | 2009-08-19 15:17:13 +0000 |
commit | f67f7744c18823e9dd26cc807055440be3098103 (patch) | |
tree | 98e1ab276a80a7ccc05802cc9a5c10b4b31adcdf /contrib/top | |
parent | 7decbe72dcf0fb6084a95d4c83f295cf89a862ca (diff) | |
download | FreeBSD-src-f67f7744c18823e9dd26cc807055440be3098103.zip FreeBSD-src-f67f7744c18823e9dd26cc807055440be3098103.tar.gz |
Explicitly line up the CPU state labels with the calculated starting column
that takes into account the width of the largest CPU ID. On systems with
> 10 CPUs the labels for the first 10 CPUs were not lined up properly
otherwise.
Approved by: re (kib)
MFC after: 1 week
Diffstat (limited to 'contrib/top')
-rw-r--r-- | contrib/top/display.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/contrib/top/display.c b/contrib/top/display.c index 0b1226c..3fca57b 100644 --- a/contrib/top/display.c +++ b/contrib/top/display.c @@ -452,6 +452,7 @@ for (cpu = 0; cpu < num_cpus; cpu++) { lastline++; /* now walk thru the names and print the line */ + Move_to(cpustates_column, y_cpustates + cpu); while ((thisname = *names++) != NULL) { if (*thisname != '\0') @@ -543,6 +544,7 @@ for (cpu = 0; cpu < num_cpus; cpu++) { printf("\nCPU %d: ", cpu); lastline++; + Move_to(cpustates_column, y_cpustates + cpu); while ((thisname = *names++) != NULL) { if (*thisname != '\0') |