Commit 1ddac7d4 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

PulseAudio: show device product name rather than card number

parent fbe71a66
...@@ -181,14 +181,10 @@ static int AddSource (services_discovery_t *sd, const pa_source_info *info) ...@@ -181,14 +181,10 @@ static int AddSource (services_discovery_t *sd, const pa_source_info *info)
return 0; return 0;
} }
char *card; const char *card = pa_proplist_gets(info->proplist, "device.product.name");
if (info->card == PA_INVALID_INDEX
|| unlikely(asprintf (&card, N_("Card %"PRIu32), info->card) == -1))
card = NULL;
services_discovery_AddItem (sd, item, services_discovery_AddItem (sd, item,
(card != NULL) ? card : N_("Generic")); (card != NULL) ? card : N_("Generic"));
d->sd = sd; d->sd = sd;
free (card);
return 0; return 0;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment