diff options
Diffstat (limited to 'www/mozilla/files/patch-nsprpub::pr::src::pthreads::ptio.c')
-rw-r--r-- | www/mozilla/files/patch-nsprpub::pr::src::pthreads::ptio.c | 45 |
1 files changed, 26 insertions, 19 deletions
diff --git a/www/mozilla/files/patch-nsprpub::pr::src::pthreads::ptio.c b/www/mozilla/files/patch-nsprpub::pr::src::pthreads::ptio.c index 4a965d4c7440..08346f235416 100644 --- a/www/mozilla/files/patch-nsprpub::pr::src::pthreads::ptio.c +++ b/www/mozilla/files/patch-nsprpub::pr::src::pthreads::ptio.c @@ -1,22 +1,29 @@ -Index: nsprpub/pr/src/pthreads/ptio.c -diff -u nsprpub/pr/src/pthreads/ptio.c.orig nsprpub/pr/src/pthreads/ptio.c ---- nsprpub/pr/src/pthreads/ptio.c.orig Fri Apr 12 03:14:39 2002 -+++ nsprpub/pr/src/pthreads/ptio.c Tue Jul 30 18:52:11 2002 -@@ -3414,6 +3414,17 @@ +--- nsprpub/pr/src/pthreads/ptio.c.orig Mon Jul 14 17:59:47 2003 ++++ nsprpub/pr/src/pthreads/ptio.c Fri Aug 29 15:39:46 2003 +@@ -189,7 +189,7 @@ + #endif + #endif + +-#ifdef DARWIN ++#if defined(DARWIN) || defined(FREEBSD) + static PRBool _pr_ipv6_v6only_on_by_default; + /* The IPV6_V6ONLY socket option is not defined on Mac OS X 10.1. */ + #ifndef IPV6_V6ONLY +@@ -1154,7 +1154,7 @@ + _pr_stderr = pt_SetMethods(2, PR_DESC_FILE, PR_FALSE, PR_TRUE); + PR_ASSERT(_pr_stdin && _pr_stdout && _pr_stderr); + +-#ifdef DARWIN ++#if defined(DARWIN) || defined(FREEBSD) + /* In Mac OS X v10.3 Panther Beta the IPV6_V6ONLY socket option + * is turned on by default, contrary to what RFC 3493, Section + * 5.3 says. So we have to turn it off. Find out whether we +@@ -3462,7 +3462,7 @@ if (osfd == -1) pt_MapError(_PR_MD_MAP_SOCKET_ERROR, errno); else { -+#if (defined(_PR_INET6_PROBE) || defined(_PR_INET6)) && \ -+ defined(__FreeBSD__) && defined(IPV6_V6ONLY) -+ if (domain == PR_AF_INET6) { -+ int opt = 0; -+ if (setsockopt(osfd, IPPROTO_IPV6, IPV6_V6ONLY, -+ &opt, sizeof(opt))) { -+ close(osfd); -+ return NULL; -+ } -+ } -+#endif - fd = pt_SetMethods(osfd, ftype, PR_FALSE, PR_FALSE); - if (fd == NULL) close(osfd); - } +-#ifdef DARWIN ++#if defined(DARWIN) || defined(FREEBSD) + if ((domain == AF_INET6) && _pr_ipv6_v6only_on_by_default) + { + int on = 0; |