bluetooth: keys: addr is null and assert in bt_keys_find_addr
When there are br connections connected, find_key_in_use call bt_conn_get_dst to get br connection's dst and bt_conn_get_dst return NULL, then bt_keys_find_addr aseert because addr is NULL. Signed-off-by: Mark Wang <yichang.wang@nxp.com>
This commit is contained in:
parent
69202a7908
commit
d166d53238
1 changed files with 1 additions and 1 deletions
|
@ -79,7 +79,7 @@ static bool key_is_in_use(uint8_t id)
|
||||||
{
|
{
|
||||||
struct key_data kdata = { false, id };
|
struct key_data kdata = { false, id };
|
||||||
|
|
||||||
bt_conn_foreach(BT_CONN_TYPE_ALL, find_key_in_use, &kdata);
|
bt_conn_foreach(BT_CONN_TYPE_LE, find_key_in_use, &kdata);
|
||||||
|
|
||||||
return kdata.in_use;
|
return kdata.in_use;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue