From c3f996e68111cb4dd79ae7fdd8a91d03e4ca2d44 Mon Sep 17 00:00:00 2001 From: Milanka Ringwald Date: Thu, 30 Jan 2025 12:09:02 +0100 Subject: [PATCH] avrcp: guarantee the existence of browsing connection associated with AVRCP connection --- src/classic/avrcp.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/classic/avrcp.c b/src/classic/avrcp.c index 588b26f13..d9693ea65 100644 --- a/src/classic/avrcp.c +++ b/src/classic/avrcp.c @@ -497,6 +497,7 @@ avrcp_connection_t * avrcp_get_connection_for_browsing_cid_for_role(avrcp_role_t while (btstack_linked_list_iterator_has_next(&it)){ avrcp_connection_t * connection = (avrcp_connection_t *)btstack_linked_list_iterator_next(&it); if (connection->role != role) continue; + if (connection->browsing_connection == NULL) continue; if (connection->avrcp_browsing_cid != browsing_cid) continue; return connection; }