diff options
author | Claudio Takahasi <claudio.takahasi@openbossa.org> | 2006-04-13 14:48:08 +0000 |
---|---|---|
committer | Claudio Takahasi <claudio.takahasi@openbossa.org> | 2006-04-13 14:48:08 +0000 |
commit | 309d97605a26e8c3dc843feb334c9529cf7ad0e8 (patch) | |
tree | e3b2e720b5c9a07cd9893c7df596d19fe6ea6728 /hcid | |
parent | d9f928803e9e3f628d93c131cd0cb8f3170333a5 (diff) |
DiscoveryCompleted signal sent without discover request fixed.
Diffstat (limited to 'hcid')
-rw-r--r-- | hcid/dbus.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/hcid/dbus.c b/hcid/dbus.c index 1143502f..3354da5f 100644 --- a/hcid/dbus.c +++ b/hcid/dbus.c @@ -1075,14 +1075,12 @@ void hcid_dbus_remote_name(bdaddr_t *local, bdaddr_t *peer, uint8_t status, char if (!disc_device_req_name(pdata)) goto failed; /* skip if a new request has been sent */ - pdata->discover_state = STATE_IDLE; - /* free discovered devices list */ slist_foreach(pdata->disc_devices, disc_device_info_free, NULL); slist_free(pdata->disc_devices); pdata->disc_devices = NULL; - if (pdata->discover_type == RESOLVE_NAMES) { + if (pdata->discover_state == STATE_RESOLVING_NAMES ) { message = dbus_message_new_signal(path, ADAPTER_INTERFACE, "DiscoveryCompleted"); @@ -1094,6 +1092,8 @@ void hcid_dbus_remote_name(bdaddr_t *local, bdaddr_t *peer, uint8_t status, char } } + pdata->discover_state = STATE_IDLE; + failed: bt_free(local_addr); bt_free(peer_addr); |