diff --git a/src/apcups.c b/src/apcups.c
index 08df0b50fbcb2cb36253bd2c97f9019f689962bb..5a03764f59f5ea53bc1ac63cd549f183d22e40d1 100644 (file)
--- a/src/apcups.c
+++ b/src/apcups.c
* Returns -1 on error
* Returns socket file descriptor otherwise
*/
-static int net_open (char *host, char *service, int port)
+static int net_open (char *host, int port)
{
int sd;
int status;
if (global_sockfd < 0)
{
- global_sockfd = net_open (host, NULL, port);
+ global_sockfd = net_open (host, port);
if (global_sockfd < 0)
{
ERROR ("apcups plugin: Connecting to the "
while ((n = net_recv (&global_sockfd, recvline, sizeof (recvline) - 1)) > 0)
{
- assert (n < sizeof (recvline));
+ assert ((unsigned int)n < sizeof (recvline));
recvline[n] = '\0';
#if APCMAIN
printf ("net_recv = `%s';\n", recvline);