From 5f09880833fe39b49881469d19f09daaf5ef27e6 Mon Sep 17 00:00:00 2001 From: Aaron McCarthy Date: Thu, 3 Jun 2010 11:35:38 +1000 Subject: Don't poll non-polling engines when configurations are in use. --- src/network/bearer/qnetworkconfigmanager_p.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/network/bearer/qnetworkconfigmanager_p.cpp b/src/network/bearer/qnetworkconfigmanager_p.cpp index 471927a..5d4274f 100644 --- a/src/network/bearer/qnetworkconfigmanager_p.cpp +++ b/src/network/bearer/qnetworkconfigmanager_p.cpp @@ -483,8 +483,10 @@ void QNetworkConfigurationManagerPrivate::pollEngines() QMutexLocker locker(&mutex); for (int i = 0; i < sessionEngines.count(); ++i) { - if ((forcedPolling && sessionEngines.at(i)->requiresPolling()) || - sessionEngines.at(i)->configurationsInUse()) { + if (!sessionEngines.at(i)->requiresPolling()) + continue; + + if (forcedPolling || sessionEngines.at(i)->configurationsInUse()) { pollingEngines.insert(i); QMetaObject::invokeMethod(sessionEngines.at(i), "requestUpdate"); } -- cgit v0.12