mozilla.patch 966 B

12345678910111213141516171819202122232425262728293031
  1. --- nsprpub/pr/include/md/_freebsd.h.orig Sat Feb 16 09:12:55 2002
  2. +++ nsprpub/pr/include/md/_freebsd.h Thu Aug 8 19:31:23 2002
  3. @@ -40,6 +40,7 @@
  4. #if __FreeBSD__ >= 2
  5. #include <osreldate.h> /* for __FreeBSD_version */
  6. #endif
  7. +#include <sys/param.h>
  8. #include <sys/syscall.h>
  9. #define PR_LINKER_ARCH "freebsd"
  10. --- nsprpub/pr/src/pthreads/ptio.c.orig Fri Apr 12 03:14:39 2002
  11. +++ nsprpub/pr/src/pthreads/ptio.c Tue Jul 30 18:52:11 2002
  12. @@ -3414,6 +3414,17 @@
  13. if (osfd == -1) pt_MapError(_PR_MD_MAP_SOCKET_ERROR, errno);
  14. else
  15. {
  16. +#if (defined(_PR_INET6_PROBE) || defined(_PR_INET6)) && \
  17. + defined(__FreeBSD__) && defined(IPV6_V6ONLY)
  18. + if (domain == PR_AF_INET6) {
  19. + int opt = 0;
  20. + if (setsockopt(osfd, IPPROTO_IPV6, IPV6_V6ONLY,
  21. + &opt, sizeof(opt))) {
  22. + close(osfd);
  23. + return NULL;
  24. + }
  25. + }
  26. +#endif
  27. fd = pt_SetMethods(osfd, ftype, PR_FALSE, PR_FALSE);
  28. if (fd == NULL) close(osfd);
  29. }