diff options
author | Frederik Gladhorn <frederik.gladhorn@digia.com> | 2014-06-25 14:42:30 +0200 |
---|---|---|
committer | The Qt Project <gerrit-noreply@qt-project.org> | 2014-06-25 15:24:01 +0200 |
commit | 3921c825d8509c2fec634e4b7133abb3e294c1ee (patch) | |
tree | 7cf45200dce1dc0ca1d0377d9edcd1308e133ea2 | |
parent | 7c833601402d536bccb1541a17755d20a1a102de (diff) | |
parent | bd20b30bf8fad9ca5e407a331a0e1d25a67b382b (diff) |
Merge "Merge remote-tracking branch 'origin/stable' into 5.3" into refs/staging/5.3
-rw-r--r-- | src/dbus/qdbusintegrator.cpp | 11 | ||||
-rw-r--r-- | src/network/kernel/qdnslookup_unix.cpp | 2 |
2 files changed, 7 insertions, 6 deletions
diff --git a/src/dbus/qdbusintegrator.cpp b/src/dbus/qdbusintegrator.cpp index 6b6ac6bc62..499e9dbd82 100644 --- a/src/dbus/qdbusintegrator.cpp +++ b/src/dbus/qdbusintegrator.cpp @@ -73,8 +73,8 @@ QT_BEGIN_NAMESPACE -static bool isDebugging; -#define qDBusDebug if (!::isDebugging); else qDebug +static QBasicAtomicInt isDebugging = Q_BASIC_ATOMIC_INITIALIZER(-1); +#define qDBusDebug if (::isDebugging == 0); else qDebug Q_GLOBAL_STATIC_WITH_ARGS(const QString, orgFreedesktopDBusString, (QLatin1String(DBUS_SERVICE_DBUS))) @@ -1022,13 +1022,12 @@ QDBusConnectionPrivate::QDBusConnectionPrivate(QObject *p) anonymousAuthenticationAllowed(false) { static const bool threads = q_dbus_threads_init_default(); - static const int debugging = qgetenv("QDBUS_DEBUG").toInt(); - ::isDebugging = debugging; + if (::isDebugging == -1) + ::isDebugging = qgetenv("QDBUS_DEBUG").toInt(); Q_UNUSED(threads) - Q_UNUSED(debugging) #ifdef QDBUS_THREAD_DEBUG - if (debugging > 1) + if (::isDebugging > 1) qdbusThreadDebug = qdbusDefaultThreadDebug; #endif diff --git a/src/network/kernel/qdnslookup_unix.cpp b/src/network/kernel/qdnslookup_unix.cpp index 108fcbaf60..8c5a0ebdba 100644 --- a/src/network/kernel/qdnslookup_unix.cpp +++ b/src/network/kernel/qdnslookup_unix.cpp @@ -160,9 +160,11 @@ void QDnsLookupRunnable::query(const int requestType, const QByteArray &requestN Q_CHECK_PTR(ns); state._u._ext.nsaddrs[0] = ns; } +#ifndef __UCLIBC__ // Set nsmap[] to indicate that nsaddrs[0] is an IPv6 address // See: https://sourceware.org/ml/libc-hacker/2002-05/msg00035.html state._u._ext.nsmap[0] = MAXNS + 1; +#endif state._u._ext.nscount6 = 1; ns->sin6_family = AF_INET6; ns->sin6_port = htons(53); |