From 929c05e23b8fb18e6ac90b7b2c81e70791f239f0 Mon Sep 17 00:00:00 2001 From: Eric Leblond Date: Tue, 18 Jun 2013 10:57:19 +0200 Subject: [PATCH] unix-socket: fix OSX build MSG_NOSIGNAL is not defined on macOSX and SO_NOSIGPIPE is used instead. --- src/unix-manager.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/unix-manager.c b/src/unix-manager.c index 5c7aa2fd1d..6bf01ef878 100644 --- a/src/unix-manager.c +++ b/src/unix-manager.c @@ -40,6 +40,13 @@ #ifdef BUILD_UNIX_SOCKET #include +// MSG_NOSIGNAL does not exists on OS X +#ifdef OS_DARWIN +# ifndef MSG_NOSIGNAL +# define MSG_NOSIGNAL SO_NOSIGPIPE +# endif +#endif + #define SOCKET_PATH LOCAL_STATE_DIR "/run/suricata/" #define SOCKET_FILENAME "suricata-command.socket" #define SOCKET_TARGET SOCKET_PATH SOCKET_FILENAME -- 2.47.3