summaryrefslogtreecommitdiffstats
path: root/hcid/dbus.c
diff options
context:
space:
mode:
authorJohan Hedberg <johan.hedberg@nokia.com>2006-09-27 10:39:45 +0000
committerJohan Hedberg <johan.hedberg@nokia.com>2006-09-27 10:39:45 +0000
commit83857f9b11fec1d48fba45f0ce83b9924c010456 (patch)
treef20ba0da4df9c3b16a67148a5263044e65eb0c5d /hcid/dbus.c
parent77d8a5189780245c3b6521864d74cdf4556b41ff (diff)
Fix pairing state when using security mode 3
Diffstat (limited to 'hcid/dbus.c')
-rw-r--r--hcid/dbus.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/hcid/dbus.c b/hcid/dbus.c
index bd09d10d..df0229fe 100644
--- a/hcid/dbus.c
+++ b/hcid/dbus.c
@@ -1540,7 +1540,16 @@ void hcid_dbus_conn_complete(bdaddr_t *local, uint8_t status, uint16_t handle, b
goto done;
}
- if (!status) {
+ if (status) {
+ struct slist *l;
+
+ l = slist_find(pdata->pin_reqs, &peer, pin_req_cmp);
+ if (l) {
+ struct pending_pin_req *p = l->data;
+ pdata->pin_reqs = slist_remove(pdata->pin_reqs, p);
+ free(p);
+ }
+ } else {
/* Sent the remote device connected signal */
message = dbus_message_new_signal(path, ADAPTER_INTERFACE, "RemoteDeviceConnected");