summaryrefslogtreecommitdiffstats
path: root/hcid
diff options
context:
space:
mode:
authorMarcel Holtmann <marcel@holtmann.org>2008-06-16 14:26:54 +0000
committerMarcel Holtmann <marcel@holtmann.org>2008-06-16 14:26:54 +0000
commit19b4c8b0e51a20a1b95ede34b092ebc56e1183ae (patch)
tree6d378c84e88e8414d8311dd410538b21dbc6954f /hcid
parentfd1ac97806d4531cb54523b3d694899afce281e7 (diff)
Allow to cancel a service discovery
Diffstat (limited to 'hcid')
-rw-r--r--hcid/device.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/hcid/device.c b/hcid/device.c
index a9a937c6..5c7584f2 100644
--- a/hcid/device.c
+++ b/hcid/device.c
@@ -1054,7 +1054,14 @@ static DBusMessage *discover_services(DBusConnection *conn,
static DBusMessage *cancel_discover(DBusConnection *conn,
DBusMessage *msg, void *user_data)
{
- /* FIXME cancel discovery */
+ struct device *device = user_data;
+ struct adapter *adapter = device->adapter;
+ bdaddr_t src,dst;
+
+ str2ba(adapter->address, &src);
+ str2ba(device->address, &dst);
+
+ bt_cancel_discovery(&src, &dst);
return dbus_message_new_method_return(msg);
}