ALSA: sb: Minor coding style fixes
authorTakashi Iwai <tiwai@suse.de>
Tue, 8 Jun 2021 14:04:36 +0000 (16:04 +0200)
committerTakashi Iwai <tiwai@suse.de>
Wed, 9 Jun 2021 15:29:37 +0000 (17:29 +0200)
commit36e7b12b219dc30a4db046756d81745bc9d69167
tree34988389b7d5563a5fa697754d18e9c43e231410
parent10dc8ad5ffe8350d71e244b27900a1939d255fe7
ALSA: sb: Minor coding style fixes

The handling of snd_ctl_new1() and snd_ctl_add() can be sometimes
tricky, as snd_ctl_add() automatically removes the passed object at
its error path.  The recent fix addressed an overlooked issue that is
relevant with that in SB driver code, and it can be a bit more
simplified by assigning to a temporary variable, i.e. storing to the
struct field only after the creation succeeds.

Link: https://lore.kernel.org/r/20210608140540.17885-3-tiwai@suse.de
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/isa/sb/emu8000.c
sound/isa/sb/sb16_csp.c