From 4d7b35b4b06ac0e99f44ed7634d1d069f1d945f4 Mon Sep 17 00:00:00 2001 From: Alex Blasche Date: Thu, 16 Jan 2014 11:35:01 +0100 Subject: Cleanup dead code in Bluez SDP discovery backend The change tweaks the discovery debug output log too. Change-Id: I4ef3e2e8ebaf0d9e593eee35a669641e3914da01 Reviewed-by: Fabian Bumberger Reviewed-by: Aaron McCarthy --- src/bluetooth/qbluetoothservicediscoveryagent_bluez.cpp | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) (limited to 'src') diff --git a/src/bluetooth/qbluetoothservicediscoveryagent_bluez.cpp b/src/bluetooth/qbluetoothservicediscoveryagent_bluez.cpp index 1a1180d7..8e2f73cd 100644 --- a/src/bluetooth/qbluetoothservicediscoveryagent_bluez.cpp +++ b/src/bluetooth/qbluetoothservicediscoveryagent_bluez.cpp @@ -161,22 +161,14 @@ void QBluetoothServiceDiscoveryAgentPrivate::_q_createdDevice(QDBusPendingCallWa delete adapter; adapter = 0; - QDBusPendingReply deviceReply = device->GetProperties(); - deviceReply.waitForFinished(); - if (deviceReply.isError()) { - qCDebug(QT_BT_BLUEZ) << "GetProperties error: " << error << deviceObjectPath.error().name(); - delete device; - return; - } - QVariantMap v = deviceReply.value(); - QStringList device_uuids = v.value(QLatin1String("UUIDs")).toStringList(); - QString pattern; foreach (const QBluetoothUuid &uuid, uuidFilter) pattern += uuid.toString().remove(QLatin1Char('{')).remove(QLatin1Char('}')) + QLatin1Char(' '); - qCDebug(QT_BT_BLUEZ) << Q_FUNC_INFO << "Discover: " << pattern.trimmed(); - QDBusPendingReply discoverReply = device->DiscoverServices(pattern.trimmed()); + pattern = pattern.trimmed(); + qCDebug(QT_BT_BLUEZ) << Q_FUNC_INFO << "Discover restrictions:" << pattern; + + QDBusPendingReply discoverReply = device->DiscoverServices(pattern); watcher = new QDBusPendingCallWatcher(discoverReply, q); QObject::connect(watcher, SIGNAL(finished(QDBusPendingCallWatcher*)), q, SLOT(_q_discoveredServices(QDBusPendingCallWatcher*))); -- cgit v1.2.3