bluez5: make node.group valid JSON

The node.group property is parsed as JSON, and as it here contains ":"
it needs to be quoted accordingly. Fixes pw_strv_parse errors in logs.
This commit is contained in:
Pauli Virtanen 2024-06-21 13:20:02 +03:00
parent 88d9d58333
commit 6b6e9c4ea9

View file

@ -1479,12 +1479,12 @@ static void emit_node_info(struct impl *this, bool full)
char *node_group = NULL;
if (this->transport && (this->transport->profile & SPA_BT_PROFILE_BAP_SINK)) {
spa_scnprintf(node_group_buf, sizeof(node_group_buf), "bluez-iso-%s-cig-%d",
spa_scnprintf(node_group_buf, sizeof(node_group_buf), "[\"bluez-iso-%s-cig-%d\"]",
this->transport->device->adapter->address,
this->transport->bap_cig);
node_group = node_group_buf;
} else if (this->transport && (this->transport->profile & SPA_BT_PROFILE_BAP_BROADCAST_SINK)) {
spa_scnprintf(node_group_buf, sizeof(node_group_buf), "bluez-iso-%s-big-%d",
spa_scnprintf(node_group_buf, sizeof(node_group_buf), "[\"bluez-iso-%s-big-%d\"]",
this->transport->device->adapter->address,
this->transport->bap_big);
node_group = node_group_buf;