Skip to content

Commit 0eb4bfe

Browse files
Vudentznashif
authored andcommitted
Bluetooth: ISO: Fix not unbind if ACL has been disconnected
If ACL has been disconnected any ISO handle shall be considered invalid as well. Signed-off-by: Luiz Augusto von Dentz <[email protected]>
1 parent b5a46db commit 0eb4bfe

File tree

1 file changed

+3
-2
lines changed
  • subsys/bluetooth/host

1 file changed

+3
-2
lines changed

subsys/bluetooth/host/iso.c

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -777,8 +777,9 @@ static void bt_iso_chan_disconnected(struct bt_iso_chan *chan)
777777

778778
bt_iso_chan_set_state(chan, BT_ISO_BOUND);
779779

780-
/* Unbind if acting as slave */
781-
if (chan->conn->role == BT_HCI_ROLE_SLAVE) {
780+
/* Unbind if acting as slave or ACL has been disconnected */
781+
if (chan->conn->role == BT_HCI_ROLE_SLAVE ||
782+
chan->conn->iso.acl->state == BT_CONN_DISCONNECTED) {
782783
bt_iso_chan_unbind(chan);
783784
}
784785

0 commit comments

Comments
 (0)