Skip to contentSkip to conversation

acpi: memory leakages in drivers/acpi/thermal.c

PATCH In review [email protected] 1 participant 1 message Apr 27, 2006

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 12/16 acpi: memory leakages in drivers/acpi/thermal.c

From: Vasily Averin <[email protected]>

acpi_thermal_write_trip_points() and acpi_thermal_add() do not call kfree() for allocated memory on the error path.

---

 drivers/acpi/thermal.c |    2 +-
 1 files changed, 1 insertion(+), 1 deletion(-)
drivers/acpi/thermal.c renamed from drivers/acpi/thermal.c~acpi-memory-leakages-in-drivers-acpi-thermalc +1 -1
diff -puN drivers/acpi/thermal.c~acpi-memory-leakages-in-drivers-acpi-thermalc drivers/acpi/thermal.c
@@ -1329,7 +1329,7 @@ static int acpi_thermal_add(struct acpi_
 
 	result = acpi_thermal_add_fs(device);
 	if (result)
-		return_VALUE(result);
+		goto end;
 
 	init_timer(&tz->timer);
 

_