diff options
author | Vsevolod Stakhov <vsevolod@FreeBSD.org> | 2017-05-25 10:35:55 +0000 |
---|---|---|
committer | Vsevolod Stakhov <vsevolod@FreeBSD.org> | 2017-05-25 10:35:55 +0000 |
commit | 1defd3c09da72a2e6b35cc02d1eb70701e74bd66 (patch) | |
tree | f4d01cb1d56e39219a422b1bf8a1ba5e49313ec8 /mail/rspamd/files | |
parent | 65b14c7154b84a5975eb87810e8dc917197d85f6 (diff) | |
download | ports-1defd3c09da72a2e6b35cc02d1eb70701e74bd66.tar.gz ports-1defd3c09da72a2e6b35cc02d1eb70701e74bd66.zip |
Notes
Diffstat (limited to 'mail/rspamd/files')
-rw-r--r-- | mail/rspamd/files/patch-ipv6-support | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/mail/rspamd/files/patch-ipv6-support b/mail/rspamd/files/patch-ipv6-support new file mode 100644 index 000000000000..1d7f36735f6b --- /dev/null +++ b/mail/rspamd/files/patch-ipv6-support @@ -0,0 +1,29 @@ +diff --git a/src/libutil/addr.c b/src/libutil/addr.c +index 1687c80bd..ee70a90f4 100644 +--- src/libutil/addr.c ++++ src/libutil/addr.c +@@ -287,8 +287,6 @@ rspamd_accept_from_socket (gint sock, rspamd_inet_addr_t **target, + addr->slen = len; + + if (addr->af == AF_UNIX) { +- addr->u.un = g_slice_alloc0 (sizeof (*addr->u.un)); +- /* Get name from the listening socket */ + len = sizeof (su); + + if (getsockname (sock, &su.sa, &len) != -1) { +diff --git a/src/libutil/addr.c b/src/libutil/addr.c +index ee70a90f4..9a278a432 100644 +--- src/libutil/addr.c ++++ src/libutil/addr.c +@@ -280,6 +280,11 @@ rspamd_accept_from_socket (gint sock, rspamd_inet_addr_t **target, + sizeof (struct in6_addr)); + } + } ++ else { ++ addr = rspamd_inet_addr_create (AF_INET6); ++ memcpy (&addr->u.in.addr.s6.sin6_addr, &su.s6.sin6_addr, ++ sizeof (struct in6_addr)); ++ } + + } + else { |