Commit 06ebe239 authored by Emil Gydesen's avatar Emil Gydesen Committed by Anas Nashif
Browse files

Bluetooth: ISO: Add NULL check in cleanup_big



In case that creating a BIG fails due to missing
ISO channel, cleanup_big would try to access a
NULL pointer.

Signed-off-by: default avatarEmil Gydesen <emil.gydesen@nordicsemi.no>
parent 77509a31
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1320,7 +1320,7 @@ static void cleanup_big(struct bt_iso_big *big)
	for (int i = 0; i < big->num_bis; i++) {
		struct bt_iso_chan *bis = big->bis[i];

		if (bis->conn) {
		if (bis != NULL && bis->conn != NULL) {
			bt_conn_unref(bis->conn);
			bis->conn = NULL;
		}