summaryrefslogtreecommitdiff
path: root/mail/exim-old
diff options
context:
space:
mode:
authorSheldon Hearn <sheldonh@FreeBSD.org>2001-07-11 11:04:01 +0000
committerSheldon Hearn <sheldonh@FreeBSD.org>2001-07-11 11:04:01 +0000
commit3b52a48f9e39d1bfb103913a0854601985d029c8 (patch)
tree03721c29f729a4e561de1ca644d0cfd1b1af52b2 /mail/exim-old
parentUpdate to 0.9.2. (diff)
Fix the IPv6 bind() call properly. The author didn't spot the flaw
in my patch when I initially submitted it. This is his fully tested version.
Notes
Notes: svn path=/head/; revision=45030
Diffstat (limited to 'mail/exim-old')
-rw-r--r--mail/exim-old/files/patch-src::daemon.c9
1 files changed, 7 insertions, 2 deletions
diff --git a/mail/exim-old/files/patch-src::daemon.c b/mail/exim-old/files/patch-src::daemon.c
index 1cfdf2b972ca..b792bbf3529c 100644
--- a/mail/exim-old/files/patch-src::daemon.c
+++ b/mail/exim-old/files/patch-src::daemon.c
@@ -1,12 +1,17 @@
--- src/daemon.c.orig Tue Jul 10 11:52:32 2001
+++ src/daemon.c Tue Jul 10 11:53:33 2001
-@@ -841,7 +841,8 @@
+@@ -841,7 +841,13 @@
for (i = 9; i >= 0; i--)
{
- if (bind(listen_sockets[sk], (struct sockaddr *)&sin, sizeof(sin)) < 0)
+ if (bind(listen_sockets[sk], (struct sockaddr *)&sin,
-+ (ipv6_address) ? sizeof(sin.v6) : sizeof(sin.v4)) < 0)
++ #ifdef HAVE_IPV6
++ ipv6_socket? sizeof(sin.v6) : sizeof(sin.v4)
++ #else
++ sizeof(sin)
++ #endif
++ ) < 0)
{
char *msg = strerror(errno);
char *addr = (ipa->address[0] == 0)? "(any)" : ipa->address;