From deac38234c118208d6ab31dcb26040e2a154ad2b Mon Sep 17 00:00:00 2001 From: Vinicius Gomes Date: Thu, 3 Apr 2008 17:55:54 +0000 Subject: hcid: fixing a segmentation fault, when the first pair failed. --- hcid/dbus-hci.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/hcid/dbus-hci.c b/hcid/dbus-hci.c index 72ea30a9..954a892b 100644 --- a/hcid/dbus-hci.c +++ b/hcid/dbus-hci.c @@ -1006,12 +1006,7 @@ int hcid_dbus_request_pin(int dev, bdaddr_t *sba, struct hci_conn_info *ci) ba2str(&ci->bdaddr, addr); - device = adapter_find_device(adapter, addr); - if (!device) { - device = device_create(connection, adapter, addr, NULL); - device->created = TRUE; - } - + device = adapter_get_device(connection, adapter, addr); if (!device) return -ENODEV; -- cgit