summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorAleksandar Sasha Babic <aleksandar.babic@nokia.com>2010-06-18 15:24:18 (GMT)
committerAleksandar Sasha Babic <aleksandar.babic@nokia.com>2010-06-18 15:24:18 (GMT)
commit65f2273f43bfca718ee51e8d491c76ef830238f7 (patch)
tree0f5d301b9a255d99c598e56427a3c69b91c4eba4 /src
parent0929c3607a01b2b2a2f3af7cdaaf8d85290bc4b7 (diff)
downloadQt-65f2273f43bfca718ee51e8d491c76ef830238f7.zip
Qt-65f2273f43bfca718ee51e8d491c76ef830238f7.tar.gz
Qt-65f2273f43bfca718ee51e8d491c76ef830238f7.tar.bz2
Debug prints and another attempt to fix QTBUG-8687 for N8.
Diffstat (limited to 'src')
-rw-r--r--src/network/kernel/qhostinfo_unix.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/src/network/kernel/qhostinfo_unix.cpp b/src/network/kernel/qhostinfo_unix.cpp
index df98d5d..79f4b9b 100644
--- a/src/network/kernel/qhostinfo_unix.cpp
+++ b/src/network/kernel/qhostinfo_unix.cpp
@@ -208,12 +208,19 @@ QHostInfo QHostInfoAgent::fromName(const QString &hostName)
#ifdef Q_ADDRCONFIG
hints.ai_flags = Q_ADDRCONFIG;
#endif
+#ifdef Q_OS_SYMBIAN
+ qDebug() << "Setting flags: 'hints.ai_flags &= AI_V4MAPPED | AI_ALL'";
+#endif
int result = getaddrinfo(aceHostname.constData(), 0, &hints, &res);
# ifdef Q_ADDRCONFIG
if (result == EAI_BADFLAGS) {
// if the lookup failed with AI_ADDRCONFIG set, try again without it
hints.ai_flags = 0;
+#ifdef Q_OS_SYMBIAN
+ qDebug() << "Setting flags: 'hints.ai_flags &= AI_V4MAPPED | AI_ALL'";
+ hints.ai_flags &= AI_V4MAPPED | AI_ALL;
+#endif
result = getaddrinfo(aceHostname.constData(), 0, &hints, &res);
}
# endif
@@ -222,6 +229,8 @@ QHostInfo QHostInfoAgent::fromName(const QString &hostName)
addrinfo *node = res;
QList<QHostAddress> addresses;
while (node) {
+ qDebug() << "getaddrinfo node: flags:" << node->ai_flags << "family:" << node->ai_family << "ai_socktype:" << node->ai_socktype << "ai_protocol:" << node->ai_protocol << "ai_addrlen:" << node->ai_addrlen;
+
if (node->ai_family == AF_INET) {
QHostAddress addr;
addr.setAddress(ntohl(((sockaddr_in *) node->ai_addr)->sin_addr.s_addr));