]> code.delx.au - pulseaudio/commit
alsa-mixer: When figuring out the max_dB of a path, use only channels that are used...
authorTanu Kaskinen <tanu.kaskinen@digia.com>
Fri, 11 Mar 2011 11:41:28 +0000 (13:41 +0200)
committerTanu Kaskinen <tanu.kaskinen@digia.com>
Fri, 11 Mar 2011 11:41:28 +0000 (13:41 +0200)
commit5715b2af3091f9be9a656dfa9b8cb778caf1c03e
tree402316370dbb59220a5513517074df17aa21d96b
parent064780d9dea6a79c4c3adb07f530e2e6d5c68c0f
alsa-mixer: When figuring out the max_dB of a path, use only channels that are used by the path elements.

Without this, p->max_dB could never be less than 0 dB, because the loop at the
end of pa_alsa_path_probe() would reset p->max_dB to 0 as soon as the loop
encountered a channel that wasn't touched by any element.

There was a similar issue for p->min_dB too (it could never be more than 0 dB),
which is also fixed by this patch.
src/modules/alsa/alsa-mixer.c