mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-01 22:58:50 -04:00
pw-top: Fallback to app name if no node name/desc exists
This commit is contained in:
parent
5a22d0bfca
commit
7a82be3361
1 changed files with 4 additions and 3 deletions
|
|
@ -361,9 +361,10 @@ static void registry_event_global(void *data, uint32_t id,
|
|||
struct node *n;
|
||||
const char *str;
|
||||
|
||||
str = spa_dict_lookup(props, PW_KEY_NODE_NAME);
|
||||
if (str == NULL)
|
||||
str = spa_dict_lookup(props, PW_KEY_NODE_DESCRIPTION);
|
||||
if ((str = spa_dict_lookup(props, PW_KEY_NODE_NAME)) == NULL &&
|
||||
(str = spa_dict_lookup(props, PW_KEY_NODE_DESCRIPTION)) == NULL) {
|
||||
str = spa_dict_lookup(props, PW_KEY_APP_NAME);
|
||||
}
|
||||
|
||||
if ((n = add_node(d, id, str)) == NULL) {
|
||||
pw_log_warn("can add node %u: %m", id);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue