Skip to content

Commit aac06ba

Browse files
Thalleykartben
authored andcommitted
Bluetooth: BAP: Broadcast Sink: Fix missing group relations
Adds missing assignments to stream->group and cleanup of ep->broadcast_sink. Signed-off-by: Emil Gydesen <[email protected]>
1 parent ff7de52 commit aac06ba

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

subsys/bluetooth/audio/bap_broadcast_sink.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -271,7 +271,9 @@ static void broadcast_sink_set_ep_state(struct bt_bap_ep *ep, uint8_t state)
271271
bt_bap_iso_unbind_ep(ep->iso, ep);
272272
stream->ep = NULL;
273273
stream->codec_cfg = NULL;
274+
stream->group = NULL;
274275
ep->stream = NULL;
276+
ep->broadcast_sink = NULL;
275277
}
276278
}
277279
}
@@ -1001,6 +1003,7 @@ static int bt_bap_broadcast_sink_setup_stream(struct bt_bap_broadcast_sink *sink
10011003

10021004
bt_bap_stream_attach(NULL, stream, ep, codec_cfg);
10031005
stream->qos = &sink->qos_cfg;
1006+
stream->group = sink;
10041007

10051008
return 0;
10061009
}
@@ -1013,6 +1016,7 @@ static void broadcast_sink_cleanup_streams(struct bt_bap_broadcast_sink *sink)
10131016
if (stream->ep != NULL) {
10141017
bt_bap_iso_unbind_ep(stream->ep->iso, stream->ep);
10151018
stream->ep->stream = NULL;
1019+
stream->ep->broadcast_sink = NULL;
10161020
stream->ep = NULL;
10171021
}
10181022

0 commit comments

Comments
 (0)