From 7db513d4bbc55cc398e1434b5121e2f1408f9baa Mon Sep 17 00:00:00 2001 From: Aaron McCarthy Date: Fri, 2 Jul 2010 13:15:54 +1000 Subject: Abort if connection to DBus cannot be established. Fixes network access issue when running Qt applications in scratchbox environment. Task-number: QT-3528 --- src/plugins/bearer/icd/qicdengine.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/plugins/bearer/icd/qicdengine.cpp b/src/plugins/bearer/icd/qicdengine.cpp index 9d1bfab..0638a36 100644 --- a/src/plugins/bearer/icd/qicdengine.cpp +++ b/src/plugins/bearer/icd/qicdengine.cpp @@ -251,6 +251,11 @@ void QIcdEngine::initialize() ICD_DBUS_API_INTERFACE, QDBusConnection::systemBus(), this); + + // abort if cannot connect to DBus. + if (!m_dbusInterface->isValid()) + return; + connect(&m_scanTimer, SIGNAL(timeout()), this, SLOT(finishAsyncConfigurationUpdate())); m_scanTimer.setSingleShot(true); -- cgit v0.12