]> err.no Git - linux-2.6/commitdiff
[ACPI] fix potential NULL dereference in acpi/video.c
authorAdrian Bunk <bunk@stusta.de>
Thu, 31 Mar 2005 03:31:35 +0000 (22:31 -0500)
committerLen Brown <len.brown@intel.com>
Tue, 12 Jul 2005 03:58:10 +0000 (23:58 -0400)
Found-by: Adrian Bunk <bunk@stusta.de>
Signed-off-by: Len Brown <len.brown@intel.com>
drivers/acpi/video.c

index 71fa1011715f36e413fa57aa1a1fe9d83528f01d..b3b352b8330af098affa6d4e22ce5e0054c7c60c 100644 (file)
@@ -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);