aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/platform/x86/asus-laptop.c
diff options
context:
space:
mode:
authorMatthew Garrett <matthew.garrett@nebula.com>2012-12-28 10:54:42 -0500
committerMatthew Garrett <matthew.garrett@nebula.com>2013-01-07 12:33:48 -0500
commit9f89748463f13c9657496b12820f09a988ce77ff (patch)
tree662d6e8236ec488f8877d099f414a9d9f8488cd3 /drivers/platform/x86/asus-laptop.c
parentf7cb13b3f27f70caacf1a0a0b4f1f9b86420ee03 (diff)
asus-laptop: Fix potential invalid pointer dereference
The 0-day build testing backend noticed that a string could be dereferenced without validation. Fix that. Signed-off-by: Matthew Garrett <matthew.garrett@nebula.com>
Diffstat (limited to 'drivers/platform/x86/asus-laptop.c')
-rw-r--r--drivers/platform/x86/asus-laptop.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/platform/x86/asus-laptop.c b/drivers/platform/x86/asus-laptop.c
index d0c519762dcf..fcde4e528819 100644
--- a/drivers/platform/x86/asus-laptop.c
+++ b/drivers/platform/x86/asus-laptop.c
@@ -1743,7 +1743,7 @@ static int asus_laptop_get_info(struct asus_laptop *asus)
1743 return -ENOMEM; 1743 return -ENOMEM;
1744 } 1744 }
1745 1745
1746 if (*string) 1746 if (string)
1747 pr_notice(" %s model detected\n", string); 1747 pr_notice(" %s model detected\n", string);
1748 1748
1749 if (!acpi_check_handle(asus->handle, METHOD_WL_STATUS, NULL)) 1749 if (!acpi_check_handle(asus->handle, METHOD_WL_STATUS, NULL))