From 1fd3aceb53116277e3744ab94281ac0fd09c6382 Mon Sep 17 00:00:00 2001 From: Claudio Takahasi Date: Fri, 22 Sep 2006 18:18:40 +0000 Subject: missing DiscoveryCompleted if GetRemoteName is called and there is inquiry running(started by NON D-Bus) --- hcid/dbus.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/hcid/dbus.c b/hcid/dbus.c index f92ae1b1..c4d1e453 100644 --- a/hcid/dbus.c +++ b/hcid/dbus.c @@ -1495,18 +1495,18 @@ void hcid_dbus_remote_name(bdaddr_t *local, bdaddr_t *peer, uint8_t status, char pdata->discovery_cancel = NULL; } - if (pdata->discover_type & RESOLVE_NAME) { - message = dbus_message_new_signal(path, - ADAPTER_INTERFACE, "DiscoveryCompleted"); - send_reply_and_unref(connection, message); - } - /* Disable name resolution for non D-Bus clients */ if (!pdata->pdiscovery_requestor) pdata->discover_type &= ~RESOLVE_NAME; } - pdata->disc_active = 0; + if (pdata->disc_active) { + message = dbus_message_new_signal(path, + ADAPTER_INTERFACE, "DiscoveryCompleted"); + send_reply_and_unref(connection, message); + + pdata->disc_active = 0; + } done: bt_free(local_addr); -- cgit