aboutsummaryrefslogtreecommitdiffstats
path: root/sound/isa/sb
diff options
context:
space:
mode:
authorDave Jones <davej@redhat.com>2006-03-06 07:28:34 -0500
committerJaroslav Kysela <perex@suse.cz>2006-03-22 04:35:57 -0500
commitbcc54f9a563f146e723ead16c76f842bcaeb694e (patch)
tree73a31717b1fb3d2b24f1d54c2b2684f90f51b99d /sound/isa/sb
parentc27e8c591854ef349fdf5bec777355dae04bb48f (diff)
[ALSA] sound/isa/sb/sb_mixer.c double kfree
Modules: SB drivers snd_ctl_add() already does the free on error. Coverity bug #957 Signed-off-by: Dave Jones <davej@redhat.com> Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound/isa/sb')
-rw-r--r--sound/isa/sb/sb_mixer.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/sound/isa/sb/sb_mixer.c b/sound/isa/sb/sb_mixer.c
index 1a6ee344dddb..490b1ca5cf58 100644
--- a/sound/isa/sb/sb_mixer.c
+++ b/sound/isa/sb/sb_mixer.c
@@ -453,10 +453,8 @@ int snd_sbmixer_add_ctl(struct snd_sb *chip, const char *name, int index, int ty
453 strlcpy(ctl->id.name, name, sizeof(ctl->id.name)); 453 strlcpy(ctl->id.name, name, sizeof(ctl->id.name));
454 ctl->id.index = index; 454 ctl->id.index = index;
455 ctl->private_value = value; 455 ctl->private_value = value;
456 if ((err = snd_ctl_add(chip->card, ctl)) < 0) { 456 if ((err = snd_ctl_add(chip->card, ctl)) < 0)
457 snd_ctl_free_one(ctl);
458 return err; 457 return err;
459 }
460 return 0; 458 return 0;
461} 459}
462 460