[PATCH] [UBUNTU:sound/isa] Fix memory leak in isa/es18xx.c

crimsun at fungus.sh.nu crimsun at fungus.sh.nu
Sat Mar 18 03:31:56 UTC 2006


UpstreamStatus: Added in upstream isa/es18xx.c r1.69

This patch from Adrian Bunk <bunk at stusta.de> fixes a memory leak
spotted by the Coverity checker in isa/es18xx.c .

Signed-off-by: Daniel T Chen <crimsun at ubuntu.com>

---

 sound/isa/es18xx.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

38c2b79fe35c13d3f4de4f2fe466b31a15356c18
diff --git a/sound/isa/es18xx.c b/sound/isa/es18xx.c
index 970e2aa..ebc703f 100644
--- a/sound/isa/es18xx.c
+++ b/sound/isa/es18xx.c
@@ -1931,6 +1931,7 @@ static int __devinit snd_audiodrive_pnp(
 	err = pnp_activate_dev(acard->devc);
 	if (err < 0) {
 		snd_printk(KERN_ERR PFX "PnP control configure failure (out of resources?)\n");
+		kfree(cfg);
 		return -EAGAIN;
 	}
 	snd_printdd("pnp: port=0x%lx\n", pnp_port_start(acard->devc, 0));
-- 
1.1.3

-- 
Daniel T. Chen            crimsun at ubuntu.com
GPG key:   www.sh.nu/~crimsun/pubkey.gpg.asc
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <https://lists.ubuntu.com/archives/kernel-team/attachments/20060317/fec65f17/attachment.sig>


More information about the kernel-team mailing list