vmstat: Update memory statistics
vmstat <n> would update most fields, but the memory statistics were only fetched the first time. References: https://bugs.debian.org/1027963 Signed-off-by: Craig Small <csmall@dropbear.xyz>
This commit is contained in:
@ -468,6 +468,9 @@ static void new_format(void)
|
||||
pswpin[tog] = VMSTAT_GET(vm_info, VMSTAT_PSWPIN, ul_int);
|
||||
pswpout[tog] = VMSTAT_GET(vm_info, VMSTAT_PSWPOUT, ul_int);
|
||||
|
||||
if (!(mem_stack = procps_meminfo_select(mem_info, Mem_items, MAX_mem)))
|
||||
xerrx(EXIT_FAILURE, _("Unable to select memory information"));
|
||||
|
||||
if (t_option) {
|
||||
(void) time( &the_time );
|
||||
tm_ptr = localtime( &the_time );
|
||||
|
Reference in New Issue
Block a user