From: Luiz Augusto von Dentz Date: Mon, 13 Mar 2023 22:51:47 +0000 (-0700) Subject: shared/bap: Fix not unregistering idle callback on detach X-Git-Tag: accepted/tizen/unified/20240117.163238~299 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=bc78fc7f3848ca76ee11fdd40790cf99572a90ff;p=platform%2Fupstream%2Fbluez.git shared/bap: Fix not unregistering idle callback on detach This make sure idle callback is unregistered before bt_gatt_client is unref. --- diff --git a/src/shared/bap.c b/src/shared/bap.c index 952b7be..7a53fbc 100644 --- a/src/shared/bap.c +++ b/src/shared/bap.c @@ -3818,6 +3818,8 @@ void bt_bap_detach(struct bt_bap *bap) bap->req = NULL; } + bt_gatt_client_idle_unregister(bap->client, bap->idle_id); + /* Cancel queued requests */ queue_remove_all(bap->reqs, NULL, NULL, bap_req_detach);