From 9bcd26813064f6ad798ad3a0be8d673b7ee02aed Mon Sep 17 00:00:00 2001 From: tmm Date: Tue, 20 Mar 2001 16:02:16 +0000 Subject: Correct the top memory stats display: convert page counts to kB. Submitted by: Andrea Campi Approved by: rwatson Pointy hat to: myself --- usr.bin/top/machine.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/usr.bin/top/machine.c b/usr.bin/top/machine.c index 33c621e..5002498 100644 --- a/usr.bin/top/machine.c +++ b/usr.bin/top/machine.c @@ -332,7 +332,12 @@ struct system_info *si; GETSYSCTL("vm.stats.vm.v_swappgsin", nspgsin); GETSYSCTL("vm.stats.vm.v_swappgsout", nspgsout); /* convert memory stats to Kbytes */ + memory_stats[0] = pagetok(memory_stats[0]); + memory_stats[1] = pagetok(memory_stats[1]); + memory_stats[2] = pagetok(memory_stats[2]); + memory_stats[3] = pagetok(memory_stats[3]); memory_stats[4] = bufspace / 1024; + memory_stats[5] = pagetok(memory_stats[5]); memory_stats[6] = -1; /* first interval */ -- cgit v1.1