From 97a275e71e3bcdeaa9d665fee4e7f01e310169a9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Barnab=C3=A1s=20P=C5=91cze?= Date: Mon, 20 Jun 2022 17:39:24 +0200 Subject: [PATCH] pulse-server: update quirks before querying the name `client_update_quirks()` may modify `client::props` depending on the "pulse.rules" section defined in the configuration file, which means that it can change the value corresponding to the "application.name" key. Therefore, `client::name` needs to be queried after that. --- src/modules/module-protocol-pulse/pulse-server.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/modules/module-protocol-pulse/pulse-server.c b/src/modules/module-protocol-pulse/pulse-server.c index 23524bb5a..1c4615de6 100644 --- a/src/modules/module-protocol-pulse/pulse-server.c +++ b/src/modules/module-protocol-pulse/pulse-server.c @@ -1034,12 +1034,12 @@ static int do_set_client_name(struct client *client, uint32_t command, uint32_t changed++; } + client_update_quirks(client); + client->name = pw_properties_get(client->props, PW_KEY_APP_NAME); pw_log_info("[%s] %s tag:%d", client->name, commands[command].name, tag); - client_update_quirks(client); - if (client->core == NULL) { client->core = pw_context_connect(impl->context, pw_properties_copy(client->props), 0);