swap plugin: Fix a bug collecting swap I/O.
authorFlorian Forster <octo@leeloo.lan.home.verplant.org>
Tue, 23 Nov 2010 17:45:49 +0000 (18:45 +0100)
committerFlorian Forster <octo@leeloo.lan.home.verplant.org>
Tue, 23 Nov 2010 17:45:49 +0000 (18:45 +0100)
src/swap.c

index 60ede04..46ba665 100644 (file)
@@ -259,7 +259,7 @@ static int swap_read (void)
                        if (numfields != 2)
                                continue;
 
-                       if (strcasecmp ("pswpin", fields[0]) != 0)
+                       if (strcasecmp ("pswpin", fields[0]) == 0)
                                strtoderive (fields[1], &swap_in);
                        else if (strcasecmp ("pswpout", fields[0]) == 0)
                                strtoderive (fields[1], &swap_out);