From f0304f45a9d561f25808178cefe634b7b0dd8fd0 Mon Sep 17 00:00:00 2001 From: Wim Taymans Date: Wed, 24 Jan 2024 12:47:32 +0100 Subject: [PATCH] jack: make sure jack clients are ALWAYS_PROCESS We need this flag to be true otherwise, we will try to hide ports from JACK clients that suspend (while still active). See #3416 --- pipewire-jack/src/pipewire-jack.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/pipewire-jack/src/pipewire-jack.c b/pipewire-jack/src/pipewire-jack.c index cf1e5f35a..aef2bbf5e 100644 --- a/pipewire-jack/src/pipewire-jack.c +++ b/pipewire-jack/src/pipewire-jack.c @@ -3258,6 +3258,14 @@ static void node_info(void *data, const struct pw_node_info *info) struct client *c = n->client; bool active; + if (info->change_mask & PW_NODE_CHANGE_MASK_PROPS) { + /* JACK clients always need ALWAYS_PROCESS=true or else they don't + * conform to the JACK API. We would try to hide the ports of + * PAUSED JACK clients, for example, even if they are active. */ + const char *str = spa_dict_lookup(info->props, PW_KEY_NODE_ALWAYS_PROCESS); + n->node.is_jack = str ? spa_atob(str) : false; + } + n->node.is_running = info->state == PW_NODE_STATE_RUNNING; active = node_is_active(c, n);