projects
/
GitHub
/
LineageOS
/
G12
/
android_kernel_amlogic_linux-4.9.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
42ddfd6
)
[PATCH] firmware/efivars: handle error
author
Jeff Garzik
<jeff@garzik.org>
Wed, 11 Oct 2006 08:22:23 +0000
(
01:22
-0700)
committer
Linus Torvalds
<torvalds@g5.osdl.org>
Wed, 11 Oct 2006 18:14:25 +0000
(11:14 -0700)
Signed-off-by: Jeff Garzik <jeff@garzik.org>
Acked-by: Matt Domsch <Matt_Domsch@dell.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
drivers/firmware/efivars.c
patch
|
blob
|
blame
|
history
diff --git
a/drivers/firmware/efivars.c
b/drivers/firmware/efivars.c
index 8ebce1c03ad77f887038924590ecfc009f782b1d..5ab5e393b882810556d80c6c7fa5071e444362b3 100644
(file)
--- a/
drivers/firmware/efivars.c
+++ b/
drivers/firmware/efivars.c
@@
-639,7
+639,12
@@
efivar_create_sysfs_entry(unsigned long variable_name_size,
kobject_set_name(&new_efivar->kobj, "%s", short_name);
kobj_set_kset_s(new_efivar, vars_subsys);
- kobject_register(&new_efivar->kobj);
+ i = kobject_register(&new_efivar->kobj);
+ if (i) {
+ kfree(short_name);
+ kfree(new_efivar);
+ return 1;
+ }
kfree(short_name);
short_name = NULL;