From: Simon Kuhnle Date: Mon, 16 Feb 2009 11:00:35 +0000 (+0100) Subject: swap plugin: Fix two typos in the *BSD code. X-Git-Tag: collectd-4.6.0~21 X-Git-Url: https://git.octo.it/?p=collectd.git;a=commitdiff_plain;h=b721e0781d022671b62b15c2407780055c1e5146 swap plugin: Fix two typos in the *BSD code. --- diff --git a/src/swap.c b/src/swap.c index 425742e9..24289abd 100644 --- a/src/swap.c +++ b/src/swap.c @@ -289,7 +289,7 @@ static int swap_read (void) } status = swapctl (SWAP_STATS, swap_entries, swap_num); - if (status != swap_entries) + if (status != swap_num) { ERROR ("swap plugin: swapctl (SWAP_STATS) failed with status %i.", status); @@ -303,7 +303,7 @@ static int swap_read (void) # define C_SWAP_BLOCK_SIZE 512 #endif - for (i = 0; i < swap_entries; i++) + for (i = 0; i < swap_num; i++) { if ((swap_entries[i].se_flags & SWF_ENABLE) == 0) continue;