From: Florian Forster Date: Sun, 9 Dec 2007 14:33:58 +0000 (+0100) Subject: apcups plugin: Removed the `complain' stuff. X-Git-Tag: collectd-4.3.0beta0~67 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=a133005c542bfda2013904499df0171177ddf4bf;p=collectd.git apcups plugin: Removed the `complain' stuff. --- diff --git a/src/apcups.c b/src/apcups.c index 174febe4..08df0b50 100644 --- a/src/apcups.c +++ b/src/apcups.c @@ -262,8 +262,6 @@ static int apc_query_server (char *host, int port, char *key; double value; - static complain_t compl; - #if APCMAIN # define PRINT_VALUE(name, val) printf(" Found property: name = %s; value = %f;\n", name, val) #else @@ -272,17 +270,13 @@ static int apc_query_server (char *host, int port, if (global_sockfd < 0) { - if ((global_sockfd = net_open (host, NULL, port)) < 0) + global_sockfd = net_open (host, NULL, port); + if (global_sockfd < 0) { - plugin_complain (LOG_ERR, &compl, "apcups plugin: " - "Connecting to the apcupsd failed."); + ERROR ("apcups plugin: Connecting to the " + "apcupsd failed."); return (-1); } - else - { - plugin_relief (LOG_NOTICE, &compl, "apcups plugin: " - "Connection re-established to the apcupsd."); - } } if (net_send (&global_sockfd, "status", 6) < 0)