From 9d8edef1a0714f73a1d91bb8eba7cb10b4491d2f Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Mon, 21 Nov 2022 20:19:29 +0100 Subject: [PATCH] client-node: guard against NULL resource When destroying, the resource can be NULL (mix->io should also be NULL ideally so we can check first). See #2847 --- src/modules/module-client-node/client-node.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/module-client-node/client-node.c b/src/modules/module-client-node/client-node.c index a33423b70..563585553 100644 --- a/src/modules/module-client-node/client-node.c +++ b/src/modules/module-client-node/client-node.c @@ -1493,7 +1493,7 @@ static int impl_mix_port_set_io(void *object, else mix->io = NULL; - if (this->resource->version >= 4 && mix->io != NULL) + if (mix->io != NULL && this->resource && this->resource->version >= 4) pw_client_node_resource_port_set_mix_info(this->resource, direction, port->port_id, mix->port.port_id, mix->peer_id, NULL);