summaryrefslogtreecommitdiff
path: root/debian
diff options
context:
space:
mode:
authorModestas Vainius <modestas@vainius.eu>2008-06-08 10:18:10 +0000
committerModestas Vainius <modestas@vainius.eu>2008-06-08 10:18:10 +0000
commit7cf68afd65cdef9cd71a7ceb17c6ba185abe0431 (patch)
treef6b7cf36f1c213564a7237ca8274669150c5fc63 /debian
parent8ff4b1bcb440b2014da39050e69d8dd66255636e (diff)
downloadqt4-x11-7cf68afd65cdef9cd71a7ceb17c6ba185abe0431.tar.gz
IPv6 fix from 4.4.1 (try2)
Diffstat (limited to 'debian')
-rw-r--r--debian/patches/73_from4.4.1_no_AAAA_when_ipv6_disabled.diff30
1 files changed, 30 insertions, 0 deletions
diff --git a/debian/patches/73_from4.4.1_no_AAAA_when_ipv6_disabled.diff b/debian/patches/73_from4.4.1_no_AAAA_when_ipv6_disabled.diff
new file mode 100644
index 0000000..df618e1
--- /dev/null
+++ b/debian/patches/73_from4.4.1_no_AAAA_when_ipv6_disabled.diff
@@ -0,0 +1,30 @@
+--- a/src/network/kernel/qhostinfo_unix.cpp 2008-04-28 16:11:19.000000000 +0300
++++ b/src/network/kernel/qhostinfo_unix.cpp 2008-06-08 02:35:23.000000000 +0300
+@@ -167,8 +167,19 @@
+ struct addrinfo hints;
+ memset(&hints, 0, sizeof(hints));
+ hints.ai_family = PF_UNSPEC;
++# ifdef AI_ADDRCONFIG
++ hints.ai_flags = AI_ADDRCONFIG;
++# endif
+
+ int result = getaddrinfo(hostName.toLatin1().constData(), 0, &hints, &res);
++# ifdef AI_ADDRCONFIG
++ if (result == EAI_BADFLAGS) {
++ // if the lookup failed with AI_ADDRCONFIG set, try again without it
++ hints.ai_flags = 0;
++ result = getaddrinfo(hostName.toLatin1().constData(), 0, &hints, &res);
++ }
++# endif
++
+ if (result == 0) {
+ addrinfo *node = res;
+ QList<QHostAddress> addresses;
+@@ -200,7 +211,6 @@
+ freeaddrinfo(res);
+ } else if (result == EAI_NONAME
+ || result == EAI_FAIL
+- || result == EAI_FAIL
+ #ifdef EAI_NODATA
+ // EAI_NODATA is deprecated in RFC 3493
+ || result == EAI_NODATA