X-Git-Url: https://git.octo.it/?a=blobdiff_plain;f=src%2Funixsock.c;h=d4bf004731abf3142253a9833a742004f48420a0;hb=5eb1fef6de7e0c8fb99e3d85063d96d7cc785f9b;hp=54a1e20d48aedf40a347bf901ff1718e518d00d5;hpb=6164fe4456716e6dc36aaa2ab617b104a7ac5ff3;p=collectd.git diff --git a/src/unixsock.c b/src/unixsock.c index 54a1e20d..d4bf0047 100644 --- a/src/unixsock.c +++ b/src/unixsock.c @@ -36,9 +36,6 @@ #include "utils_cmd_putval.h" #include "utils_cmd_putnotif.h" -/* Folks without pthread will need to disable this plugin. */ -#include - #include #include @@ -151,7 +148,7 @@ static int us_open_socket (void) do { - char *grpname; + const char *grpname; struct group *g; struct group sg; char grbuf[2048]; @@ -368,7 +365,7 @@ static void *us_server_thread (void __attribute__((unused)) *arg) pthread_exit ((void *) 1); } - remote_fd = (int *) malloc (sizeof (int)); + remote_fd = malloc (sizeof (*remote_fd)); if (remote_fd == NULL) { char errbuf[1024];