summaryrefslogtreecommitdiffstats
path: root/drivers/platform
diff options
context:
space:
mode:
authorDan Carpenter <error27@gmail.com>2011-03-15 10:07:37 +0300
committerMatthew Garrett <mjg@redhat.com>2011-03-28 06:46:07 -0400
commita1d6086739c5b8f23a48e02e62b0e495321a2122 (patch)
tree5cd8b2d2c777256dd5f2b122d3c8a82bea5d1307 /drivers/platform
parent0986f25fbba8827762b35222bb45d2fbb2d72fa4 (diff)
downloadop-kernel-dev-a1d6086739c5b8f23a48e02e62b0e495321a2122.zip
op-kernel-dev-a1d6086739c5b8f23a48e02e62b0e495321a2122.tar.gz
asus-wmi: potential NULL dereference in show_call()
In the earlier check we assumed that "obj" could be NULL. I looked at some of the other places that call evaluate_object() and they check for NULL as well. Signed-off-by: Dan Carpenter <error27@gmail.com> Signed-off-by: Matthew Garrett <mjg@redhat.com>
Diffstat (limited to 'drivers/platform')
-rw-r--r--drivers/platform/x86/asus-wmi.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/platform/x86/asus-wmi.c b/drivers/platform/x86/asus-wmi.c
index a038595..efc776c 100644
--- a/drivers/platform/x86/asus-wmi.c
+++ b/drivers/platform/x86/asus-wmi.c
@@ -1343,7 +1343,7 @@ static int show_call(struct seq_file *m, void *data)
else
seq_printf(m, "%#x(%#x, %#x) = t:%d\n", asus->debug.method_id,
asus->debug.dev_id, asus->debug.ctrl_param,
- obj->type);
+ obj ? obj->type : -1);
kfree(obj);
OpenPOWER on IntegriCloud