--- profiles/audio/transport.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/profiles/audio/transport.c b/profiles/audio/transport.c index 4a81d85..c3e26f4 100644 --- a/profiles/audio/transport.c +++ b/profiles/audio/transport.c @@ -107,6 +107,8 @@ struct media_transport { void *data; }; +static GSList *transports = NULL; + static const char *state2str(transport_state_t state) { switch (state) { @@ -703,6 +705,8 @@ static void media_transport_free(void *data) { struct media_transport *transport = data; + transports = g_slist_remove(transports, transport); + if (transport->owner) media_transport_remove_owner(transport); @@ -816,6 +820,8 @@ struct media_transport *media_transport_create(struct media_endpoint *endpoint, goto fail; } + transports = g_slist_append(transports, transport); + return transport; fail: -- 1.7.11.7 -- To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html