All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drivers/acpi/ec.c fix a small memory leak
@ 2010-02-02 12:12 ` Darren Jenkins
  0 siblings, 0 replies; 11+ messages in thread
From: Darren Jenkins @ 2010-02-02 12:12 UTC (permalink / raw)
  To: Kernel Janitors, Len Brown, linux ACPI
  Cc: Linux Kernel Mailing List, astarikovskiy

Plug a very small leak in acpi_ec_ecdt_probe()

Coverity CID: 13319

Signed-off-by: Darren Jenkins <darrenrjenkins@gmail.com> 

diff --git drivers/acpi/ec.c drivers/acpi/ec.c
index d6471bb..13061dc 100644
--- drivers/acpi/ec.c
+++ drivers/acpi/ec.c
@@ -1009,8 +1009,10 @@ int __init acpi_ec_ecdt_probe(void)
 	/* fall through */
 	}
 
-	if (EC_FLAGS_SKIP_DSDT_SCAN)
+	if (EC_FLAGS_SKIP_DSDT_SCAN) {
+		kfree(saved_ec);
 		return -ENODEV;
+	}
 
 	/* This workaround is needed only on some broken machines,
 	 * which require early EC, but fail to provide ECDT */



^ permalink raw reply related	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2010-02-03 11:33 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-02-02 12:12 [PATCH] drivers/acpi/ec.c fix a small memory leak Darren Jenkins
2010-02-02 12:12 ` Darren Jenkins
2010-02-02 15:35 ` Alexey Starikovskiy
2010-02-02 15:35   ` Alexey Starikovskiy
2010-02-03  6:12   ` Dan Carpenter
2010-02-03  6:12     ` Dan Carpenter
2010-02-03  6:12     ` Dan Carpenter
2010-02-03 11:06   ` Bernd Petrovitsch
2010-02-03 11:06     ` Bernd Petrovitsch
2010-02-03 11:33   ` Darren Jenkins
2010-02-03 11:33     ` Darren Jenkins

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.