solaris-fixes branch: Complain in the syslog if `swapctl' failes.
authorocto <octo>
Thu, 15 Jun 2006 20:28:20 +0000 (20:28 +0000)
committerocto <octo>
Thu, 15 Jun 2006 20:28:20 +0000 (20:28 +0000)
Shouldn't happen, but one ought to know if it does.

src/swap.c

index 86df6f7..1595cde 100644 (file)
@@ -149,7 +149,11 @@ static void swap_read (void)
        struct anoninfo ai;
 
        if (swapctl (SC_AINFO, &ai) == -1)
+       {
+               syslog (LOG_ERR, "swap plugin: swapctl failed: %s",
+                               strerror (errno));
                return;
+       }
 
        /*
         * Calculations from: