Skip to content

Commit 5a79839

Browse files
committed
ALSA: cs5530: Fix resource leak in error path
Bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=44741 Signed-off-by: Takashi Iwai <[email protected]>
1 parent fbaf6a5 commit 5a79839

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

sound/pci/cs5530.c

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -142,8 +142,7 @@ static int __devinit snd_cs5530_create(struct snd_card *card,
142142

143143
mem = pci_ioremap_bar(pci, 0);
144144
if (mem == NULL) {
145-
kfree(chip);
146-
pci_disable_device(pci);
145+
snd_cs5530_free(chip);
147146
return -EBUSY;
148147
}
149148

0 commit comments

Comments
 (0)