diff --git a/base/commands.c b/base/commands.c index f22186840..789d02494 100644 --- a/base/commands.c +++ b/base/commands.c @@ -35,7 +35,6 @@ extern int sigrestart; static int command_file_fd; -static FILE *command_file_fp; static int command_file_created = FALSE; /* The command file worker process */ @@ -117,7 +116,7 @@ int close_command_file(void) command_file_created = FALSE; /* close the command file */ - fclose(command_file_fp); + close(command_file_fd); /* unlink the pipe */ unlink(command_file); diff --git a/cgi/Makefile.in b/cgi/Makefile.in index de31bafc0..8efdad781 100644 --- a/cgi/Makefile.in +++ b/cgi/Makefile.in @@ -33,7 +33,7 @@ CGIEXTRAS=@CGIEXTRAS@ CP=@CP@ CC=@CC@ -CFLAGS=-Wall -I.. -I@builddir@ -I$(SRC_INCLUDE) -I@top_srcdir@ -I$(BLD_LIB) @CFLAGS@ @DEFS@ -DNSCGI +CFLAGS=-Wall -I.. -I@builddir@ -I$(SRC_INCLUDE) -I@top_srcdir@ -I$(BLD_INCLUDE) -I$(BLD_LIB) @CFLAGS@ @DEFS@ -DNSCGI JSONFLAGS=-DJSON_NAGIOS_4X # Compiler flags for optimization (overrides default) diff --git a/lib/test-squeue.c b/lib/test-squeue.c index 08debce3b..fbdc46e3a 100644 --- a/lib/test-squeue.c +++ b/lib/test-squeue.c @@ -46,9 +46,6 @@ typedef struct sq_test_event { static time_t sq_high = 0; static int sq_walker(squeue_event *evt, void *arg) { - static int walks = 0; - - walks++; t(sq_high <= evt->when.tv_sec, "sq_high: %lu; evt->when: %lu\n", sq_high, evt->when.tv_sec); sq_high = (unsigned long)evt->when.tv_sec;