From 8cb101fc55f66e6ef80c11f1bbfe3a232ac032ec Mon Sep 17 00:00:00 2001 From: Luiz Augusto von Dentz Date: Fri, 17 Mar 2023 09:14:18 -0700 Subject: [PATCH] bap: Fix not continue selecting if endpoint respond with an error If the endpoint respond with an error we shall decrement selecting counter and proceed to check if there is any stream that can be configured. --- profiles/audio/bap.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/profiles/audio/bap.c b/profiles/audio/bap.c index 05b9c9a..bdd99b9 100644 --- a/profiles/audio/bap.c +++ b/profiles/audio/bap.c @@ -629,7 +629,8 @@ static void select_cb(struct bt_bap_pac *pac, int err, struct iovec *caps, if (err) { error("err %d", err); - return; + ep->data->selecting--; + goto done; } ep->caps = util_iov_dup(caps, 1); @@ -644,6 +645,7 @@ static void select_cb(struct bt_bap_pac *pac, int err, struct iovec *caps, DBG("selecting %d", ep->data->selecting); ep->data->selecting--; +done: if (ep->data->selecting) return; -- 2.7.4