aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAlexander Moisseev <moiseev@mezonplus.ru>2017-08-08 08:57:35 +0300
committerAlexander Moisseev <moiseev@mezonplus.ru>2017-08-08 08:57:35 +0300
commite0c27de1821073bd8e5e1b1ca9fb553eb26c9c5f (patch)
tree7eb7caf6bd612ce5e0947ba1709921629ce49c05
parent8bcdcfc6c8e93dda7e5eeb2122bf2ed5772f00a3 (diff)
downloadrspamd-e0c27de1821073bd8e5e1b1ca9fb553eb26c9c5f.tar.gz
rspamd-e0c27de1821073bd8e5e1b1ca9fb553eb26c9c5f.zip
[Fix] Fix build on FreeBSD
-rw-r--r--src/rspamd_proxy.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/rspamd_proxy.c b/src/rspamd_proxy.c
index be0980102..6474188cc 100644
--- a/src/rspamd_proxy.c
+++ b/src/rspamd_proxy.c
@@ -2011,6 +2011,11 @@ proxy_accept_socket (gint fd, short what, void *arg)
rspamd_inet_address_get_port (addr));
#ifdef TCP_NODELAY
+
+ #ifndef SOL_TCP
+ #define SOL_TCP IPPROTO_TCP
+ #endif
+
gint sopt = 1;
if (setsockopt (nfd, SOL_TCP, TCP_NODELAY, &sopt, sizeof (sopt)) == -1) {