X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Ftcpconns.c;h=50d8efbfd01acf8d2c37cf3799a5656f081de431;hb=6c170c99262c1d9678943122428f6d9f1353aaf6;hp=9fdd16e9c1b30b7d336c18e0b3620c8a587340e4;hpb=af12cc40e48331f8c98294239cef60393218a46d;p=collectd.git diff --git a/src/tcpconns.c b/src/tcpconns.c index 9fdd16e9..50d8efbf 100644 --- a/src/tcpconns.c +++ b/src/tcpconns.c @@ -76,7 +76,6 @@ #endif #if KERNEL_LINUX -#include #include #if HAVE_LINUX_INET_DIAG_H #include @@ -459,7 +458,7 @@ static int conn_read_netlink(void) { if (fd < 0) { ERROR("tcpconns plugin: conn_read_netlink: socket(AF_NETLINK, SOCK_RAW, " "NETLINK_INET_DIAG) failed: %s", - sstrerror(errno, buf, sizeof(buf))); + STRERRNO); return -1; } @@ -490,7 +489,7 @@ static int conn_read_netlink(void) { if (sendmsg(fd, &msg, 0) < 0) { ERROR("tcpconns plugin: conn_read_netlink: sendmsg(2) failed: %s", - sstrerror(errno, buf, sizeof(buf))); + STRERRNO); close(fd); return -1; } @@ -514,7 +513,7 @@ static int conn_read_netlink(void) { continue; ERROR("tcpconns plugin: conn_read_netlink: recvmsg(2) failed: %s", - sstrerror(errno, buf, sizeof(buf))); + STRERRNO); close(fd); return -1; } else if (status == 0) {