RE: [PATCH 09/14] Big kfree NULL check cleanup - misc remaining drivers

From: Brown, Len
Date: Thu Oct 13 2005 - 15:04:13 EST


Re: ACPI files

Acked-by: Len Brown <len.brown@xxxxxxxxx>

thanks,
-Len

ps. I'm okay with reducing the routine below
to a 2-liner if you're so inclined.

>--- linux-2.6.14-rc4-orig/drivers/acpi/container.c
>2005-10-11 22:41:04.000000000 +0200
>+++ linux-2.6.14-rc4/drivers/acpi/container.c 2005-10-12
>16:31:11.000000000 +0200
>@@ -118,11 +118,9 @@ static int acpi_container_remove(struct
> {
> acpi_status status = AE_OK;
> struct acpi_container *pc = NULL;
>- pc = (struct acpi_container *)acpi_driver_data(device);
>-
>- if (pc)
>- kfree(pc);
>
>+ pc = (struct acpi_container *)acpi_driver_data(device);
>+ kfree(pc);
> return status;
> }
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/