summaryrefslogtreecommitdiff
path: root/www/privoxy
diff options
context:
space:
mode:
authorjoerg <joerg@pkgsrc.org>2013-08-30 16:56:08 +0000
committerjoerg <joerg@pkgsrc.org>2013-08-30 16:56:08 +0000
commit53b1bc22608908b6a767e9e8e98a06ad259e7a76 (patch)
tree04e639aff736b40a878ffd2b49cbb22caf5e583b /www/privoxy
parent572f9da6a3668ea52bbed56a9c3d0862227516c0 (diff)
downloadpkgsrc-53b1bc22608908b6a767e9e8e98a06ad259e7a76.tar.gz
Deal with gethostbyname_r fallout.
Diffstat (limited to 'www/privoxy')
-rw-r--r--www/privoxy/distinfo4
-rw-r--r--www/privoxy/patches/patch-ag23
2 files changed, 19 insertions, 8 deletions
diff --git a/www/privoxy/distinfo b/www/privoxy/distinfo
index a594686ee8a..a3abd9850d8 100644
--- a/www/privoxy/distinfo
+++ b/www/privoxy/distinfo
@@ -1,4 +1,4 @@
-$NetBSD: distinfo,v 1.19 2012/02/10 13:21:08 mjl Exp $
+$NetBSD: distinfo,v 1.20 2013/08/30 16:56:08 joerg Exp $
SHA1 (privoxy-3.0.19-stable-src.tar.gz) = a82287cbf48375ef449d021473a366baeca49250
RMD160 (privoxy-3.0.19-stable-src.tar.gz) = 6a4d6914d2cec8f90b82c9b2ab28dda55b271561
@@ -6,4 +6,4 @@ Size (privoxy-3.0.19-stable-src.tar.gz) = 1722316 bytes
SHA1 (patch-aa) = c263d2a4b9522a33613f82ab2bc18d5c2b554b21
SHA1 (patch-ab) = 6ab77caae5e6ac2b67c4c795af38db4da1310c61
SHA1 (patch-ac) = 6b0f5c2b32108cf4366a9f7feaad8a5be634e2e9
-SHA1 (patch-ag) = 631b73e17d2f825ae6c2fa2d832db98e166030ba
+SHA1 (patch-ag) = 64957682dbb3ff8b78ef47cc936d591facf9eb3a
diff --git a/www/privoxy/patches/patch-ag b/www/privoxy/patches/patch-ag
index 9a4ef44ce21..e7ea35aa42b 100644
--- a/www/privoxy/patches/patch-ag
+++ b/www/privoxy/patches/patch-ag
@@ -1,11 +1,12 @@
-$NetBSD: patch-ag,v 1.4 2011/04/26 21:23:26 mjl Exp $
+$NetBSD: patch-ag,v 1.5 2013/08/30 16:56:09 joerg Exp $
---- jbsockets.c.orig 2010-07-26 13:30:09.000000000 +0200
-+++ jbsockets.c 2011-04-26 19:47:46.000000000 +0200
-@@ -1112,6 +1112,13 @@
+--- jbsockets.c.orig 2011-12-10 17:26:30.000000000 +0000
++++ jbsockets.c
+@@ -1240,7 +1240,14 @@ unsigned long resolve_hostname_to_ip(con
{
struct sockaddr_in inaddr;
struct hostent *hostp;
+-#if defined(HAVE_GETHOSTBYNAME_R_6_ARGS) || defined(HAVE_GETHOSTBYNAME_R_5_ARGS) || defined(HAVE_GETHOSTBYNAME_R_3_ARGS)
+#if defined(__NetBSD__)
+ struct hostent result;
+ struct sockaddr_in raddr;
@@ -13,10 +14,20 @@ $NetBSD: patch-ag,v 1.4 2011/04/26 21:23:26 mjl Exp $
+
+ memset(&result, '\0', sizeof(struct hostent));
+#endif
- #if defined(HAVE_GETHOSTBYNAME_R_6_ARGS) || defined(HAVE_GETHOSTBYNAME_R_5_ARGS) || defined(HAVE_GETHOSTBYNAME_R_3_ARGS)
++#if (defined(HAVE_GETHOSTBYNAME_R_6_ARGS) || defined(HAVE_GETHOSTBYNAME_R_5_ARGS) || defined(HAVE_GETHOSTBYNAME_R_3_ARGS)) && !defined(__NetBSD__)
struct hostent result;
#if defined(HAVE_GETHOSTBYNAME_R_6_ARGS) || defined(HAVE_GETHOSTBYNAME_R_5_ARGS)
-@@ -1163,6 +1170,39 @@
+ char hbuf[HOSTENT_BUFFER_SIZE];
+@@ -1260,7 +1267,7 @@ unsigned long resolve_hostname_to_ip(con
+ if ((inaddr.sin_addr.s_addr = inet_addr(host)) == -1)
+ {
+ unsigned int dns_retries = 0;
+-#if defined(HAVE_GETHOSTBYNAME_R_6_ARGS)
++#if defined(HAVE_GETHOSTBYNAME_R_6_ARGS) && !defined(__NetBSD__)
+ while (gethostbyname_r(host, &result, hbuf,
+ HOSTENT_BUFFER_SIZE, &hostp, &thd_err)
+ && (thd_err == TRY_AGAIN) && (dns_retries++ < MAX_DNS_RETRIES))
+@@ -1291,6 +1298,39 @@ unsigned long resolve_hostname_to_ip(con
{
hostp = NULL;
}