From edf94c7d2a21142b0cf9613dbbc1ff7a48f456ef Mon Sep 17 00:00:00 2001 From: "M. Sean Finney" Date: Mon, 13 Mar 2006 17:59:23 +0000 Subject: fix for (tracker id 1420741) "check_swap: incorrect totals for multiple partitions (BSD)" thanks to scott thompson git-svn-id: https://nagiosplug.svn.sourceforge.net/svnroot/nagiosplug/nagiosplug/trunk@1323 f882894a-f735-0410-b71e-b25c423dba1c diff --git a/plugins/check_swap.c b/plugins/check_swap.c index 21a3bc8..fa98974 100644 --- a/plugins/check_swap.c +++ b/plugins/check_swap.c @@ -290,8 +290,8 @@ main (int argc, char **argv) } for(i=0;ise_nblks / conv_factor; - dskused_mb = (float) ent->se_inuse / conv_factor; + dsktotal_mb = (float) ent[i].se_nblks / conv_factor; + dskused_mb = (float) ent[i].se_inuse / conv_factor; dskfree_mb = ( dsktotal_mb - dskused_mb ); if(allswaps && dsktotal_mb > 0){ -- cgit v0.10-9-g596f