Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(256)

Unified Diff: nspr/pr/src/pthreads/ptio.c

Issue 200653003: Update to NSPR 4.10.4. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/deps/third_party/nss/
Patch Set: Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « nspr/pr/src/misc/prtrace.c ('k') | nspr/pr/src/pthreads/ptsynch.c » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: nspr/pr/src/pthreads/ptio.c
===================================================================
--- nspr/pr/src/pthreads/ptio.c (revision 257452)
+++ nspr/pr/src/pthreads/ptio.c (working copy)
@@ -3400,6 +3400,8 @@
extern PRBool _pr_ipv6_is_present(void);
PR_IMPLEMENT(PRBool) _pr_test_ipv6_socket()
{
+ int osfd;
+
#if defined(DARWIN)
/*
* Disable IPv6 if Darwin version is less than 7.0.0 (OS X 10.3). IPv6 on
@@ -3412,24 +3414,18 @@
}
#endif
-#if defined(LINUX)
- /* If /proc/net/if_inet6 exists, the Linux kernel supports IPv6. */
- int rv = access("/proc/net/if_inet6", F_OK);
- return (rv == 0);
-#else
/*
* HP-UX only: HP-UX IPv6 Porting Guide (dated February 2001)
* suggests that we call open("/dev/ip6", O_RDWR) to determine
* whether IPv6 APIs and the IPv6 stack are on the system.
* Our portable test below seems to work fine, so I am using it.
*/
- PRInt32 osfd = socket(AF_INET6, SOCK_STREAM, 0);
+ osfd = socket(AF_INET6, SOCK_STREAM, 0);
if (osfd != -1) {
close(osfd);
return PR_TRUE;
}
return PR_FALSE;
-#endif
}
#endif /* _PR_INET6_PROBE */
#endif
« no previous file with comments | « nspr/pr/src/misc/prtrace.c ('k') | nspr/pr/src/pthreads/ptsynch.c » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698