Don't redraw the disk names on every update. This was apparently done

to handle changes to the set of disks selected, but it is unnecessary
for that since the whole screen is redrawn when this set is changed.
It was also buggy:
- MAXDRIVES*6 = 42 was hard-coded as only 30 spaces in a string literal,
  the last 2 disk names were not cleared as intended
- when the extended vmstats are active, clearing of even 30 columns
  overruns the ozfod value field by 3 columns.  This was harmless because
  the field is much wider than necessary.
This commit is contained in:
Bruce Evans 2006-04-30 09:13:59 +00:00
parent a864f9d61c
commit 3bccedcdf8
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=158174

View File

@ -560,14 +560,8 @@ showkre()
PUTRATE(v_intr, GENSTATROW + 1, GENSTATCOL + 15, 4);
PUTRATE(v_soft, GENSTATROW + 1, GENSTATCOL + 20, 4);
PUTRATE(v_vm_faults, GENSTATROW + 1, GENSTATCOL + 25, 4);
mvprintw(DISKROW, DISKCOL + 5, " ");
for (i = 0, lc = 0; i < num_devices && lc < MAXDRIVES; i++)
if (dev_select[i].selected) {
char tmpstr[80];
sprintf(tmpstr, "%s%d", dev_select[i].device_name,
dev_select[i].unit_number);
mvprintw(DISKROW, DISKCOL + 5 + 6 * lc,
" %5.5s", tmpstr);
switch(state) {
case TIME:
dinfo(i, ++lc, &cur, &last);