mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-10-29 05:40:27 -04:00
client-node0: clean up resource
This commit is contained in:
parent
b91a718018
commit
180f2b0f20
1 changed files with 8 additions and 1 deletions
|
|
@ -1227,7 +1227,8 @@ static void client_node0_resource_destroy(void *data)
|
|||
true,
|
||||
&node->data_source);
|
||||
}
|
||||
pw_impl_node_destroy(this->node);
|
||||
if (this->node)
|
||||
pw_impl_node_destroy(this->node);
|
||||
}
|
||||
|
||||
static void node_initialized(void *data)
|
||||
|
|
@ -1260,8 +1261,11 @@ static void node_initialized(void *data)
|
|||
static void node_free(void *data)
|
||||
{
|
||||
struct impl *impl = data;
|
||||
struct pw_impl_client_node0 *this = &impl->this;
|
||||
struct spa_system *data_system = impl->node.data_system;
|
||||
|
||||
this->node = NULL;
|
||||
|
||||
pw_log_debug("client-node %p: free", &impl->this);
|
||||
node_clear(&impl->node);
|
||||
|
||||
|
|
@ -1270,6 +1274,9 @@ static void node_free(void *data)
|
|||
|
||||
spa_hook_remove(&impl->node_listener);
|
||||
|
||||
if (this->resource)
|
||||
pw_resource_destroy(this->resource);
|
||||
|
||||
pw_array_clear(&impl->mems);
|
||||
|
||||
if (impl->fds[0] != -1)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue