mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-04 13:30:12 -05:00
resource: destroy old core_resource
If there is already a core_resource when we are going to make a new one, remove the old one. This can happen when there is a version switch.
This commit is contained in:
parent
905e5af058
commit
d2e7f75071
4 changed files with 8 additions and 2 deletions
|
|
@ -320,6 +320,9 @@ static void on_start(void *data, uint32_t version)
|
|||
|
||||
pw_log_debug("version %d", version);
|
||||
|
||||
if (client->core_resource != NULL)
|
||||
pw_resource_remove(client->core_resource);
|
||||
|
||||
if (pw_global_bind(pw_impl_core_get_global(client->core), client,
|
||||
PW_PERM_RWX, version, 0) < 0)
|
||||
return;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue