From: Adrian Bunk Date: Thu, 31 Mar 2005 03:31:35 +0000 (-0500) Subject: [ACPI] fix potential NULL dereference in acpi/video.c X-Git-Tag: v2.6.13-rc3~10^2^2~16 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=7334571f724df7a19f48cc974e991e00afde1e2f;p=linux-2.6 [ACPI] fix potential NULL dereference in acpi/video.c Found-by: Adrian Bunk Signed-off-by: Len Brown --- diff --git a/drivers/acpi/video.c b/drivers/acpi/video.c index 71fa101171..b3b352b833 100644 --- a/drivers/acpi/video.c +++ b/drivers/acpi/video.c @@ -1585,7 +1585,7 @@ acpi_video_switch_output( ACPI_FUNCTION_TRACE("acpi_video_switch_output"); list_for_each_safe(node, next, &video->video_device_list) { - struct acpi_video_device * dev = container_of(node, struct acpi_video_device, entry); + dev = container_of(node, struct acpi_video_device, entry); status = acpi_video_device_get_state(dev, &state); if (state & 0x2){ dev_next = container_of(node->next, struct acpi_video_device, entry);