Skip to content

Commit 430595f

Browse files
committed
bt: info: cleanup BT connection on failed GATT read
This happens for example when pouch device require authentication, which is not enabled (yet) in pouch-device. Signed-off-by: Marcin Niestroj <m.niestroj@emb.dev>
1 parent 6330d16 commit 430595f

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

lib/bt/info.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@ static uint8_t info_read_cb(struct bt_conn *conn,
3636
if (err)
3737
{
3838
LOG_ERR("Failed to read BLE GATT %s (err %d)", "info", err);
39+
info_cleanup(conn);
40+
pouch_gateway_bt_finished(conn);
3941
return BT_GATT_ITER_STOP;
4042
}
4143

0 commit comments

Comments
 (0)