]> git.baikalelectronics.ru Git - kernel.git/commit
ALSA: jack: Fix endless loop at unique index detection
authorTakashi Iwai <tiwai@suse.de>
Fri, 26 Jun 2015 04:59:57 +0000 (06:59 +0200)
committerTakashi Iwai <tiwai@suse.de>
Fri, 26 Jun 2015 04:59:57 +0000 (06:59 +0200)
commit7f43231e730691ecb9ed3707c37b70c8e30d7da8
tree8b79256e1f51cee31805bcc210d2bd39811662dd
parentef8384122c577f4f262830f8a8d1810848e7f91b
ALSA: jack: Fix endless loop at unique index detection

While the commit [721c4a098dd0: ALSA: jack: Fix the id uniqueness
check] fixes the wrong string check, it leads to a worse result -- the
loop in get_available_index() goes into an endless loop.  The cause is
that snd_ctl_find_id() returns the object assigned to the numid if
it's set.  Thus it points to the previous entry again.

This patch clears the numid field for the next call properly.

Reported-and-tested-by: Tomáš Pružina <pruzinat@gmail.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/core/ctljack.c