FreeBSD: Fixed mulitple compile issues in plugins.

Also fixed headers for Freebsd in test tools.
This commit is contained in:
Andre Lorbach 2015-07-14 12:41:37 +00:00
parent 3739e6c116
commit 2edfb087b8
7 changed files with 25 additions and 2 deletions

View File

@ -175,7 +175,7 @@ struct modConfData_s {
static modConfData_t *loadModConf = NULL;/* modConf ptr to use for the current load process */
static modConfData_t *runModConf = NULL;/* modConf ptr to use for the current load process */
#if HAVE_INOTIFY_INIT
#if HAVE_INOTIFY_INIT
/* support for inotify mode */
/* we need to track directories */
@ -1869,12 +1869,15 @@ CODESTARTmodExit
objRelease(errmsg, CORE_COMPONENT);
objRelease(prop, CORE_COMPONENT);
objRelease(ruleset, CORE_COMPONENT);
#if HAVE_INOTIFY_INIT
/* we use these vars only in inotify mode */
if(dirs != NULL) {
free(dirs->active.listeners);
free(dirs->configured.listeners);
free(dirs);
}
free(wdmap);
#endif
ENDmodExit

View File

@ -31,7 +31,11 @@
#include <errno.h>
#include <unistd.h>
#include <fcntl.h>
#if defined(__FreeBSD__)
#include <sys/wait.h>
#else
#include <wait.h>
#endif
#include <sys/uio.h>
#include "conf.h"
#include "syslogd-types.h"

View File

@ -36,7 +36,11 @@
#include <errno.h>
#include <unistd.h>
#include <fcntl.h>
#if defined(__FreeBSD__)
#include <sys/wait.h>
#else
#include <wait.h>
#endif
#include <pthread.h>
#include "conf.h"
#include "syslogd-types.h"

View File

@ -28,7 +28,9 @@
#include <arpa/inet.h>
#include <sys/types.h>
#include <sys/socket.h>
#if defined(__FreeBSD__)
#include <netinet/in.h>
#endif
static char *targetIP = "127.0.0.1";
static int targetPort = 13500;

View File

@ -7,6 +7,9 @@
#include <fcntl.h>
#include <unistd.h>
#include <arpa/inet.h>
#if defined(__FreeBSD__)
#include <netinet/in.h>
#endif
static void
errout(char *reason)

View File

@ -26,7 +26,11 @@
#include "config.h"
#include <stdio.h>
#include <stdlib.h>
#if defined(__FreeBSD__)
#include <sys/time.h>
#else
#include <time.h>
#endif
int main(int argc, char *argv[])
{

View File

@ -36,6 +36,9 @@
#include <getopt.h>
#include <sys/un.h>
#include <netdb.h>
#if defined(__FreeBSD__)
#include <sys/socket.h>
#endif
char *sockName = NULL;
int sock;