Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8dcfec36 authored by Jakub Pawlowski's avatar Jakub Pawlowski Committed by Andre Eisenbach
Browse files

Pick proper addres type for unknown devices

Change-Id: I46641d0fe065b5e5a6620dc34c770429ac8dbe11
parent 0ce7052e
Loading
Loading
Loading
Loading
+2 −9
Original line number Diff line number Diff line
@@ -2219,18 +2219,11 @@ BOOLEAN l2cu_create_conn (tL2C_LCB *p_lcb, tBT_TRANSPORT transport)
#endif

#if (BLE_INCLUDED == TRUE)
    tBT_DEVICE_TYPE     dev_type;
    tBLE_ADDR_TYPE      addr_type;


    BTM_ReadDevInfo(p_lcb->remote_bd_addr, &dev_type, &addr_type);

    if (transport == BT_TRANSPORT_LE)
    {
    if (transport == BT_TRANSPORT_LE) {
        if (!controller_get_interface()->supports_ble())
            return FALSE;

        p_lcb->ble_addr_type = addr_type;
        p_lcb->ble_addr_type = BTM_IS_PUBLIC_BDA(p_lcb->remote_bd_addr) ? BLE_ADDR_PUBLIC : BLE_ADDR_RANDOM;
        p_lcb->transport = BT_TRANSPORT_LE;

        return (l2cble_create_conn(p_lcb));