projects
/
profile
/
ivi
/
kernel-x86-ivi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
bcdd323
)
efivars: memory leak on error in create_efivars_bin_attributes()
author
Dan Carpenter
<error27@gmail.com>
Fri, 18 Mar 2011 07:12:14 +0000
(10:12 +0300)
committer
Greg Kroah-Hartman
<gregkh@suse.de>
Tue, 19 Apr 2011 23:45:50 +0000
(16:45 -0700)
This is a cut and paste bug. We intended to free ->del_var and
->new_var but we only free ->new_var.
Signed-off-by: Dan Carpenter <error27@gmail.com>
Acked-by: Mike Waychison <mikew@google.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/firmware/efivars.c
patch
|
blob
|
history
diff --git
a/drivers/firmware/efivars.c
b/drivers/firmware/efivars.c
index
ff0c373
..
ff2fe40
100644
(file)
--- a/
drivers/firmware/efivars.c
+++ b/
drivers/firmware/efivars.c
@@
-677,8
+677,8
@@
create_efivars_bin_attributes(struct efivars *efivars)
return 0;
out_free:
- kfree(efivars->
new
_var);
- efivars->
new
_var = NULL;
+ kfree(efivars->
del
_var);
+ efivars->
del
_var = NULL;
kfree(efivars->new_var);
efivars->new_var = NULL;
return error;