systat - fix bug in vmmeter when switching to it via ':pv'.
authorMatthew Dillon <dillon@apollo.backplane.com>
Sat, 6 Jun 2009 21:22:30 +0000 (14:22 -0700)
committerMatthew Dillon <dillon@apollo.backplane.com>
Sat, 6 Jun 2009 21:22:30 +0000 (14:22 -0700)
If systat is started with something and then switched to vmmeter via ':pv'
vmmeter failed to display.  Fixing the return value for the init function
solves the problem.

usr.bin/systat/vmmeter.c

index e23112b..d798549 100644 (file)
@@ -54,7 +54,7 @@ getvmm(void)
 int
 initvmm(void)
 {
-       return 0;
+       return 1;
 }
 
 void
@@ -173,7 +173,6 @@ openvmm(void)
 void
 closevmm(WINDOW *w)
 {
-
        if (vmm_cur != NULL)
                free(vmm_cur);
        if (vmm_prev != NULL)