]> git.alsa-project.org Git - alsa-lib.git/commit
mixer: add documentation about postcondition of removal event processing
authorTakashi Sakamoto <o-takashi@sakamocchi.jp>
Mon, 27 Jun 2022 00:24:29 +0000 (09:24 +0900)
committerJaroslav Kysela <perex@perex.cz>
Mon, 27 Jun 2022 11:38:25 +0000 (13:38 +0200)
commit351a237b2df497e78ac2d4666040e02118e924e8
treea368ebf21ace85a71f95ebf9891c05edc0b45532
parent65c4796a8567a7eb5234972220af6b390d924161
mixer: add documentation about postcondition of removal event processing

PulseAudio and PipeWire seems to appear including careless code to
process events of mixer element in implementation of mixer class.

 * https://lore.kernel.org/alsa-devel/YrbxZ2b+3rIdi7Ut@workstation/

They register own implementation of mixer class. At addition event,
they attach own mixer element into hcontrol element. However at removal
event, they never detach the mixer element from hcontrol element. They
hit assertion in mixer API internal due to unsatisfied postcondition.

This commit adds documentation about postcondition of removal event
processing so that developer for implementation of mixer class easily
realize the way to satisfy the postcondition.

Fixes: https://github.com/alsa-project/alsa-lib/pull/244
Signed-off-by: Takashi Sakamoto <o-takashi@sakamocchi.jp>
Signed-off-by: Jaroslav Kysela <perex@perex.cz>
src/mixer/mixer.c