Diff between b88e6602e8f59ab611eaa83f0f5a0e4f1047a950 and 0a749634f5972e741137844d0e2174d8ba1444c5

Changed Files

File Additions Deletions Status
src/shared/micp.c +3 -0 modified

Full Patch

diff --git a/src/shared/micp.c b/src/shared/micp.c
index 90d05b3..b82bd92 100644
--- a/src/shared/micp.c
+++ b/src/shared/micp.c
@@ -138,6 +138,7 @@ void bt_micp_detach(struct bt_micp *micp)
 	if (!queue_remove(sessions, micp))
 		return;
 
+	bt_gatt_client_idle_unregister(micp->client, micp->idle_id);
 	bt_gatt_client_unref(micp->client);
 	micp->client = NULL;
 
@@ -175,6 +176,7 @@ static void micp_free(void *data)
 
 	micp_db_free(micp->rdb);
 
+	queue_destroy(micp->notify, free);
 	queue_destroy(micp->pending, NULL);
 	queue_destroy(micp->ready_cbs, micp_ready_free);
 
@@ -594,6 +596,7 @@ struct bt_micp *bt_micp_new(struct gatt_db *ldb, struct gatt_db *rdb)
 	micp->ldb = mdb;
 	micp->pending = queue_new();
 	micp->ready_cbs = queue_new();
+	micp->notify = queue_new();
 
 	if (!rdb)
 		goto done;