X-Git-Url: https://git.octo.it/?a=blobdiff_plain;ds=sidebyside;f=src%2Fswap.c;h=30daa4b118329f7556d0d578a9ec0d0369dfc787;hb=98ab507c640ffa46aadd1f8486f353e66a6929fb;hp=629d1a1e747fd516439123dee4e2e84a3806a38e;hpb=3904b4b9fd1a53c93f31d8fec709a7b7b8300513;p=collectd.git diff --git a/src/swap.c b/src/swap.c index 629d1a1e..30daa4b1 100644 --- a/src/swap.c +++ b/src/swap.c @@ -239,7 +239,7 @@ static int swap_read (void) /* {{{ */ sstrerror (errno, errbuf, sizeof (errbuf))); } - if ((swap_total == 0LL) || ((swap_free + swap_cached) > swap_total)) + if ((swap_free + swap_cached) > swap_total) return (-1); swap_used = swap_total - (swap_free + swap_cached);