Bluetooth: host: Log failure to initiatie security for bonded peer
Log failure to initiatet security for bonded peer when GATT wants to initiate security for CCCs for the remote. Signed-off-by: Joakim Andersson <joakim.andersson@nordicsemi.no>
This commit is contained in:
parent
8d53def576
commit
b9a586821e
1 changed files with 6 additions and 1 deletions
|
@ -4849,7 +4849,12 @@ void bt_gatt_connected(struct bt_conn *conn)
|
|||
*/
|
||||
if (IS_ENABLED(CONFIG_BT_SMP) &&
|
||||
bt_conn_get_security(conn) < data.sec) {
|
||||
bt_conn_set_security(conn, data.sec);
|
||||
int err = bt_conn_set_security(conn, data.sec);
|
||||
|
||||
if (err) {
|
||||
BT_WARN("Failed to set security for bonded peer (%d)",
|
||||
err);
|
||||
}
|
||||
}
|
||||
|
||||
#if defined(CONFIG_BT_GATT_CLIENT)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue