mirror of
https://gitlab.freedesktop.org/pulseaudio/pulseaudio.git
synced 2025-11-04 13:29:59 -05:00
protocol-native: log who changes card profiles
Some volume control applications, including gnome-control-center[1], Budgie Volume Control[2] and possibly something in xfce4 too[3], sometimes do unwanted card profile changes. This patch makes it possible to see from the log which application requested a profile change, which makes it easier to detect when an application misbehaves. [1] https://bugzilla.gnome.org/show_bug.cgi?id=762932 [2] https://bugs.freedesktop.org/show_bug.cgi?id=93903#c41 [3] https://bugs.freedesktop.org/show_bug.cgi?id=93903#c40
This commit is contained in:
parent
b6777d7f09
commit
2432270a73
1 changed files with 5 additions and 0 deletions
|
|
@ -4721,6 +4721,11 @@ static void command_set_card_profile(pa_pdispatch *pd, uint32_t command, uint32_
|
|||
|
||||
CHECK_VALIDITY(c->pstream, profile, tag, PA_ERR_NOENTITY);
|
||||
|
||||
pa_log_info("Application \"%s\" requests card profile change. card = %s, profile = %s",
|
||||
pa_strnull(pa_proplist_gets(c->client->proplist, PA_PROP_APPLICATION_NAME)),
|
||||
card->name,
|
||||
profile->name);
|
||||
|
||||
if ((ret = pa_card_set_profile(card, profile, true)) < 0) {
|
||||
pa_pstream_send_error(c->pstream, tag, -ret);
|
||||
return;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue