OSDN Git Service
(root)
/
sagit-ice-cold
/
kernel_xiaomi_msm8998.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0528f35
)
[media] rc/redrat3: dereferencing null pointer
author
Dan Carpenter
<error27@gmail.com>
Thu, 26 May 2011 08:55:08 +0000
(
05:55
-0300)
committer
Mauro Carvalho Chehab
<mchehab@redhat.com>
Wed, 27 Jul 2011 20:52:24 +0000
(17:52 -0300)
In the original code, if the allocation failed we dereference "rr3"
when it was NULL.
Acked-by: Jarod Wilson <jarod@redhat.com>
Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
drivers/media/rc/redrat3.c
patch
|
blob
|
history
diff --git
a/drivers/media/rc/redrat3.c
b/drivers/media/rc/redrat3.c
index
5147767
..
4582ef7
100644
(file)
--- a/
drivers/media/rc/redrat3.c
+++ b/
drivers/media/rc/redrat3.c
@@
-1186,7
+1186,7
@@
static int __devinit redrat3_dev_probe(struct usb_interface *intf,
rr3 = kzalloc(sizeof(*rr3), GFP_KERNEL);
if (rr3 == NULL) {
dev_err(dev, "Memory allocation failure\n");
- goto
error
;
+ goto
no_endpoints
;
}
rr3->dev = &intf->dev;