Code

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 86df6f753c589166ec92ddf02e62176c45c8f319..1595cdecbcaee1831504a891bb70ebef11286fea 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: