diff --git a/Makefile b/Makefile index 309b554..347b10d 100755 --- a/Makefile +++ b/Makefile @@ -4,7 +4,7 @@ CC ?= gcc CFLAGS += -Wall -DHAVE_GETOPT_LONG -DUSE_SSL -#CFLAGS += -DSETPROCTITLE +CFLAGS += -DSETPROCTITLE LDFLAGS += -lssl BINDIR = /usr/local/bin INSTALLPATH = $(DESTDIR)/$(BINDIR) diff --git a/setproctitle.c b/setproctitle.c index 4d22a99..e6eccf3 100644 --- a/setproctitle.c +++ b/setproctitle.c @@ -164,7 +164,7 @@ initsetproctitle(argc, argv, envp) if (p == NULL) return -1; environ[i] = strncpy(p, envp[i], len); - p[len - 1] = NULL; + p[len - 1] = (int)NULL; } environ[i] = NULL;