1 #! /bin/sh /usr/share/dpatch/dpatch-run
2 ## 32_bind_fixup.dpatch by <roland@debian.org>
4 ## All lines beginning with `## DP:' are a description of the patch.
5 ## DP: Work around bind problems on startup (Closes: #534735)
8 diff -urNad '--exclude=CVS' '--exclude=.svn' privoxy~/jbsockets.c privoxy/jbsockets.c
9 --- privoxy~/jbsockets.c
10 +++ privoxy/jbsockets.c
14 memset(&hints, 0, sizeof(struct addrinfo));
15 - if (hostnam == NULL)
18 - * XXX: This is a hack. The right thing to do
19 - * would be to bind to both AF_INET and AF_INET6.
20 - * This will also fail if there is no AF_INET
21 - * version available.
23 - hints.ai_family = AF_INET;
27 - hints.ai_family = AF_UNSPEC;
29 + hints.ai_family = AF_UNSPEC;
30 hints.ai_socktype = SOCK_STREAM;
31 hints.ai_flags = AI_PASSIVE;
32 hints.ai_protocol = 0; /* Really any stream protocol or TCP only */