projects
/
oweals
/
u-boot.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
be09372
)
efi_loader: SetVariable() fix illegal return
author
Heinrich Schuchardt
<xypron.glpk@gmx.de>
Mon, 23 Sep 2019 20:18:09 +0000
(22:18 +0200)
committer
Heinrich Schuchardt
<xypron.glpk@gmx.de>
Mon, 23 Sep 2019 20:53:25 +0000
(22:53 +0200)
We always have to return via EFI_EXIT() from EFIAPI functions.
Coverity reported an unreachable line and a resource leak.
Fixes: commit
6d2f27c5fd60
("efi_loader: variable: support APPEND_WRITE")
Reported-by: Coverity Scan CID 253575, CID 184095
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
lib/efi_loader/efi_variable.c
patch
|
blob
|
history
diff --git
a/lib/efi_loader/efi_variable.c
b/lib/efi_loader/efi_variable.c
index 48ee255f879b59fc9871d920e440fecd46f473d7..22ad271bd8524173522a3263862a30d9a0aafb46 100644
(file)
--- a/
lib/efi_loader/efi_variable.c
+++ b/
lib/efi_loader/efi_variable.c
@@
-470,7
+470,7
@@
efi_status_t EFIAPI efi_set_variable(u16 *variable_name,
if (attributes & EFI_VARIABLE_APPEND_WRITE) {
if (!prefix(old_val, "(blob)")) {
- ret
urn
EFI_DEVICE_ERROR;
+ ret
=
EFI_DEVICE_ERROR;
goto out;
}
old_size = strlen(old_val);