Browse Source

ACPI: fix memory leak in acpi_thermal_add() error path

Signed-off-by: Vasily Averin <vvs@sw.ru>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Len Brown <len.brown@intel.com>
Vasily Averin 19 years ago
parent
commit
09047e75f6
1 changed files with 1 additions and 1 deletions
  1. 1 1
      drivers/acpi/thermal.c

+ 1 - 1
drivers/acpi/thermal.c

@@ -1342,7 +1342,7 @@ static int acpi_thermal_add(struct acpi_device *device)
 
 	result = acpi_thermal_add_fs(device);
 	if (result)
-		return_VALUE(result);
+		goto end;
 
 	init_timer(&tz->timer);