diff options
author | ume <ume@FreeBSD.org> | 2003-01-22 22:30:20 +0800 |
---|---|---|
committer | ume <ume@FreeBSD.org> | 2003-01-22 22:30:20 +0800 |
commit | c78519057f7bfde0bff03cba5613d0c2b7e0e913 (patch) | |
tree | 4a49b83af564c805029140a8acaeb103b3bb47f6 | |
parent | 0db633a844faf611d2d8a9af5e495405f6e874d6 (diff) | |
download | freebsd-ports-gnome-c78519057f7bfde0bff03cba5613d0c2b7e0e913.tar.gz freebsd-ports-gnome-c78519057f7bfde0bff03cba5613d0c2b7e0e913.tar.zst freebsd-ports-gnome-c78519057f7bfde0bff03cba5613d0c2b7e0e913.zip |
better workaround against PF_LOCAL.
-rw-r--r-- | mail/cyrus-imapd/files/patch-df | 28 | ||||
-rw-r--r-- | mail/cyrus-imapd2/files/patch-df | 21 | ||||
-rw-r--r-- | mail/cyrus-imapd2/files/patch-master::service-thread.c | 21 | ||||
-rw-r--r-- | mail/cyrus-imapd22/files/patch-df | 21 | ||||
-rw-r--r-- | mail/cyrus-imapd22/files/patch-master::service-thread.c | 21 | ||||
-rw-r--r-- | mail/cyrus-imapd23/files/patch-df | 21 | ||||
-rw-r--r-- | mail/cyrus-imapd23/files/patch-master::service-thread.c | 21 | ||||
-rw-r--r-- | mail/cyrus-imapd24/files/patch-df | 21 | ||||
-rw-r--r-- | mail/cyrus-imapd24/files/patch-master::service-thread.c | 21 |
9 files changed, 74 insertions, 122 deletions
diff --git a/mail/cyrus-imapd/files/patch-df b/mail/cyrus-imapd/files/patch-df index 93540e209402..69a0841343ee 100644 --- a/mail/cyrus-imapd/files/patch-df +++ b/mail/cyrus-imapd/files/patch-df @@ -1,22 +1,14 @@ Index: master/service.c -=================================================================== -RCS file: /usr/home/ume/ncvs/src/cyrus-imapd/master/service.c,v -retrieving revision 1.2 -diff -u -r1.2 service.c ---- master/service.c 2001/02/01 14:11:43 1.2 -+++ master/service.c 2001/02/01 22:10:35 -@@ -99,7 +99,13 @@ +diff -u master/service.c.orig master/service.c +--- master/service.c.orig Wed Jan 22 22:52:36 2003 ++++ master/service.c Wed Jan 22 22:57:20 2003 +@@ -102,6 +102,9 @@ + struct sockaddr_storage sin; + socklen_t len = sizeof(sin); ++ /* XXX: old FreeBSD didn't fill sockaddr correctly against AF_UNIX */ ++ sin.ss_family = AF_UNIX; ++ /* is this a connection from the local host? */ if (getpeername(fd, (struct sockaddr *) &sin, &len) == 0) { -- if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { -+ switch (((struct sockaddr *)&sin)->sa_family) { -+ case AF_INET: -+#ifdef INET6 -+ case AF_INET6: -+#endif -+ break; -+ default: - return 1; - } - } + if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { diff --git a/mail/cyrus-imapd2/files/patch-df b/mail/cyrus-imapd2/files/patch-df index e95e795d2092..69a0841343ee 100644 --- a/mail/cyrus-imapd2/files/patch-df +++ b/mail/cyrus-imapd2/files/patch-df @@ -1,19 +1,14 @@ Index: master/service.c diff -u master/service.c.orig master/service.c ---- master/service.c.orig Thu Aug 15 06:02:41 2002 -+++ master/service.c Fri Aug 16 00:28:31 2002 -@@ -103,8 +103,13 @@ +--- master/service.c.orig Wed Jan 22 22:52:36 2003 ++++ master/service.c Wed Jan 22 22:57:20 2003 +@@ -102,6 +102,9 @@ + struct sockaddr_storage sin; socklen_t len = sizeof(sin); ++ /* XXX: old FreeBSD didn't fill sockaddr correctly against AF_UNIX */ ++ sin.ss_family = AF_UNIX; ++ /* is this a connection from the local host? */ -+ memset(&sin, 0, len); if (getpeername(fd, (struct sockaddr *) &sin, &len) == 0) { -- if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { -+ switch (((struct sockaddr *)&sin)->sa_family) { -+ case AF_INET: -+ case AF_INET6: -+ break; -+ default: - return 1; - } - } + if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { diff --git a/mail/cyrus-imapd2/files/patch-master::service-thread.c b/mail/cyrus-imapd2/files/patch-master::service-thread.c index ea5dfd8b0b2e..9a2016c3c64a 100644 --- a/mail/cyrus-imapd2/files/patch-master::service-thread.c +++ b/mail/cyrus-imapd2/files/patch-master::service-thread.c @@ -1,19 +1,14 @@ Index: master/service-thread.c diff -u master/service-thread.c.orig master/service-thread.c ---- master/service-thread.c.orig Fri Sep 13 18:43:06 2002 -+++ master/service-thread.c Fri Sep 13 19:15:50 2002 -@@ -100,8 +100,13 @@ +--- master/service-thread.c.orig Wed Jan 22 22:52:36 2003 ++++ master/service-thread.c Wed Jan 22 23:09:52 2003 +@@ -99,6 +99,9 @@ + struct sockaddr_storage sin; socklen_t len = sizeof(sin); ++ /* XXX: old FreeBSD didn't fill sockaddr correctly against AF_UNIX */ ++ sin.ss_family = AF_UNIX; ++ /* is this a connection from the local host? */ -+ memset(&sin, 0, len); if (getpeername(fd, (struct sockaddr *) &sin, &len) == 0) { -- if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { -+ switch (((struct sockaddr *)&sin)->sa_family) { -+ case AF_INET: -+ case AF_INET6: -+ break; -+ default: - return 1; - } - } + if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { diff --git a/mail/cyrus-imapd22/files/patch-df b/mail/cyrus-imapd22/files/patch-df index e95e795d2092..69a0841343ee 100644 --- a/mail/cyrus-imapd22/files/patch-df +++ b/mail/cyrus-imapd22/files/patch-df @@ -1,19 +1,14 @@ Index: master/service.c diff -u master/service.c.orig master/service.c ---- master/service.c.orig Thu Aug 15 06:02:41 2002 -+++ master/service.c Fri Aug 16 00:28:31 2002 -@@ -103,8 +103,13 @@ +--- master/service.c.orig Wed Jan 22 22:52:36 2003 ++++ master/service.c Wed Jan 22 22:57:20 2003 +@@ -102,6 +102,9 @@ + struct sockaddr_storage sin; socklen_t len = sizeof(sin); ++ /* XXX: old FreeBSD didn't fill sockaddr correctly against AF_UNIX */ ++ sin.ss_family = AF_UNIX; ++ /* is this a connection from the local host? */ -+ memset(&sin, 0, len); if (getpeername(fd, (struct sockaddr *) &sin, &len) == 0) { -- if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { -+ switch (((struct sockaddr *)&sin)->sa_family) { -+ case AF_INET: -+ case AF_INET6: -+ break; -+ default: - return 1; - } - } + if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { diff --git a/mail/cyrus-imapd22/files/patch-master::service-thread.c b/mail/cyrus-imapd22/files/patch-master::service-thread.c index ea5dfd8b0b2e..9a2016c3c64a 100644 --- a/mail/cyrus-imapd22/files/patch-master::service-thread.c +++ b/mail/cyrus-imapd22/files/patch-master::service-thread.c @@ -1,19 +1,14 @@ Index: master/service-thread.c diff -u master/service-thread.c.orig master/service-thread.c ---- master/service-thread.c.orig Fri Sep 13 18:43:06 2002 -+++ master/service-thread.c Fri Sep 13 19:15:50 2002 -@@ -100,8 +100,13 @@ +--- master/service-thread.c.orig Wed Jan 22 22:52:36 2003 ++++ master/service-thread.c Wed Jan 22 23:09:52 2003 +@@ -99,6 +99,9 @@ + struct sockaddr_storage sin; socklen_t len = sizeof(sin); ++ /* XXX: old FreeBSD didn't fill sockaddr correctly against AF_UNIX */ ++ sin.ss_family = AF_UNIX; ++ /* is this a connection from the local host? */ -+ memset(&sin, 0, len); if (getpeername(fd, (struct sockaddr *) &sin, &len) == 0) { -- if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { -+ switch (((struct sockaddr *)&sin)->sa_family) { -+ case AF_INET: -+ case AF_INET6: -+ break; -+ default: - return 1; - } - } + if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { diff --git a/mail/cyrus-imapd23/files/patch-df b/mail/cyrus-imapd23/files/patch-df index e95e795d2092..69a0841343ee 100644 --- a/mail/cyrus-imapd23/files/patch-df +++ b/mail/cyrus-imapd23/files/patch-df @@ -1,19 +1,14 @@ Index: master/service.c diff -u master/service.c.orig master/service.c ---- master/service.c.orig Thu Aug 15 06:02:41 2002 -+++ master/service.c Fri Aug 16 00:28:31 2002 -@@ -103,8 +103,13 @@ +--- master/service.c.orig Wed Jan 22 22:52:36 2003 ++++ master/service.c Wed Jan 22 22:57:20 2003 +@@ -102,6 +102,9 @@ + struct sockaddr_storage sin; socklen_t len = sizeof(sin); ++ /* XXX: old FreeBSD didn't fill sockaddr correctly against AF_UNIX */ ++ sin.ss_family = AF_UNIX; ++ /* is this a connection from the local host? */ -+ memset(&sin, 0, len); if (getpeername(fd, (struct sockaddr *) &sin, &len) == 0) { -- if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { -+ switch (((struct sockaddr *)&sin)->sa_family) { -+ case AF_INET: -+ case AF_INET6: -+ break; -+ default: - return 1; - } - } + if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { diff --git a/mail/cyrus-imapd23/files/patch-master::service-thread.c b/mail/cyrus-imapd23/files/patch-master::service-thread.c index ea5dfd8b0b2e..9a2016c3c64a 100644 --- a/mail/cyrus-imapd23/files/patch-master::service-thread.c +++ b/mail/cyrus-imapd23/files/patch-master::service-thread.c @@ -1,19 +1,14 @@ Index: master/service-thread.c diff -u master/service-thread.c.orig master/service-thread.c ---- master/service-thread.c.orig Fri Sep 13 18:43:06 2002 -+++ master/service-thread.c Fri Sep 13 19:15:50 2002 -@@ -100,8 +100,13 @@ +--- master/service-thread.c.orig Wed Jan 22 22:52:36 2003 ++++ master/service-thread.c Wed Jan 22 23:09:52 2003 +@@ -99,6 +99,9 @@ + struct sockaddr_storage sin; socklen_t len = sizeof(sin); ++ /* XXX: old FreeBSD didn't fill sockaddr correctly against AF_UNIX */ ++ sin.ss_family = AF_UNIX; ++ /* is this a connection from the local host? */ -+ memset(&sin, 0, len); if (getpeername(fd, (struct sockaddr *) &sin, &len) == 0) { -- if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { -+ switch (((struct sockaddr *)&sin)->sa_family) { -+ case AF_INET: -+ case AF_INET6: -+ break; -+ default: - return 1; - } - } + if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { diff --git a/mail/cyrus-imapd24/files/patch-df b/mail/cyrus-imapd24/files/patch-df index e95e795d2092..69a0841343ee 100644 --- a/mail/cyrus-imapd24/files/patch-df +++ b/mail/cyrus-imapd24/files/patch-df @@ -1,19 +1,14 @@ Index: master/service.c diff -u master/service.c.orig master/service.c ---- master/service.c.orig Thu Aug 15 06:02:41 2002 -+++ master/service.c Fri Aug 16 00:28:31 2002 -@@ -103,8 +103,13 @@ +--- master/service.c.orig Wed Jan 22 22:52:36 2003 ++++ master/service.c Wed Jan 22 22:57:20 2003 +@@ -102,6 +102,9 @@ + struct sockaddr_storage sin; socklen_t len = sizeof(sin); ++ /* XXX: old FreeBSD didn't fill sockaddr correctly against AF_UNIX */ ++ sin.ss_family = AF_UNIX; ++ /* is this a connection from the local host? */ -+ memset(&sin, 0, len); if (getpeername(fd, (struct sockaddr *) &sin, &len) == 0) { -- if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { -+ switch (((struct sockaddr *)&sin)->sa_family) { -+ case AF_INET: -+ case AF_INET6: -+ break; -+ default: - return 1; - } - } + if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { diff --git a/mail/cyrus-imapd24/files/patch-master::service-thread.c b/mail/cyrus-imapd24/files/patch-master::service-thread.c index ea5dfd8b0b2e..9a2016c3c64a 100644 --- a/mail/cyrus-imapd24/files/patch-master::service-thread.c +++ b/mail/cyrus-imapd24/files/patch-master::service-thread.c @@ -1,19 +1,14 @@ Index: master/service-thread.c diff -u master/service-thread.c.orig master/service-thread.c ---- master/service-thread.c.orig Fri Sep 13 18:43:06 2002 -+++ master/service-thread.c Fri Sep 13 19:15:50 2002 -@@ -100,8 +100,13 @@ +--- master/service-thread.c.orig Wed Jan 22 22:52:36 2003 ++++ master/service-thread.c Wed Jan 22 23:09:52 2003 +@@ -99,6 +99,9 @@ + struct sockaddr_storage sin; socklen_t len = sizeof(sin); ++ /* XXX: old FreeBSD didn't fill sockaddr correctly against AF_UNIX */ ++ sin.ss_family = AF_UNIX; ++ /* is this a connection from the local host? */ -+ memset(&sin, 0, len); if (getpeername(fd, (struct sockaddr *) &sin, &len) == 0) { -- if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { -+ switch (((struct sockaddr *)&sin)->sa_family) { -+ case AF_INET: -+ case AF_INET6: -+ break; -+ default: - return 1; - } - } + if (((struct sockaddr *)&sin)->sa_family == AF_UNIX) { |