Author: jhb
Date: Mon Jul 2 20:08:11 2012
New Revision: 238020
URL: http://svn.freebsd.org/changeset/base/238020
Log:
Fix two layout bugs in the previous change:
- Properly increase y_mem when per-CPU stats are enabled.
- Update y_arc for per-CPU stats being enabled/disabled.
MFC after: 3 days
Modified:
head/usr.bin/top/machine.c
Modified: head/usr.bin/top/machine.c
==============================================================================
--- head/usr.bin/top/machine.c Mon Jul 2 20:07:09 2012 (r238019)
+++ head/usr.bin/top/machine.c Mon Jul 2 20:08:11 2012 (r238020)
@@ -263,6 +263,7 @@ update_layout(void)
{
y_mem = 3;
+ y_arc = 4;
y_swap = 4 + arc_enabled;
y_idlecursor = 5 + arc_enabled;
y_message = 5 + arc_enabled;
@@ -271,7 +272,8 @@ update_layout(void)
Header_lines = 7 + arc_enabled;
if (pcpu_stats) {
- y_mem = ncpus - 1;
+ y_mem += ncpus - 1;
+ y_arc += ncpus - 1;
y_swap += ncpus - 1;
y_idlecursor += ncpus - 1;
y_message += ncpus - 1;
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/svn-src-all
To unsubscribe, send any mail to "[email protected]"