mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-04 13:30:12 -05:00
media-session: improve shutdown
First emit a remove of all objects. Then signal a session destroy and then destroy the context.
This commit is contained in:
parent
24ab22db12
commit
686a5cf47e
3 changed files with 22 additions and 5 deletions
|
|
@ -405,6 +405,7 @@ static void proxy_destroy(void *data)
|
|||
spa_list_remove(&endpoint->link);
|
||||
spa_hook_remove(&endpoint->proxy_listener);
|
||||
spa_hook_remove(&endpoint->client_endpoint_listener);
|
||||
endpoint->client_endpoint = NULL;
|
||||
}
|
||||
|
||||
static void proxy_bound(void *data, uint32_t id)
|
||||
|
|
@ -537,7 +538,8 @@ static struct endpoint *create_endpoint(struct node *node, struct endpoint *moni
|
|||
|
||||
static void destroy_endpoint(struct endpoint *endpoint)
|
||||
{
|
||||
pw_proxy_destroy((struct pw_proxy*)endpoint->client_endpoint);
|
||||
if (endpoint->client_endpoint)
|
||||
pw_proxy_destroy((struct pw_proxy*)endpoint->client_endpoint);
|
||||
}
|
||||
|
||||
/** fallback, one stream for each node */
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue