diff options
author | Ilias Apalodimas <ilias.apalodimas@linaro.org> | 2022-11-10 10:21:24 +0200 |
---|---|---|
committer | Heinrich Schuchardt <heinrich.schuchardt@canonical.com> | 2022-11-16 08:34:06 +0100 |
commit | 9fb3269ab39d3b3b1db43296b5d2619238eaa8b0 (patch) | |
tree | 4719bb11fa11a88c3c95527de505653d0f60a5c9 | |
parent | 2b94359e9c489061b66cc7dcefddbb6adb5ba9f8 (diff) | |
download | u-boot-9fb3269ab39d3b3b1db43296b5d2619238eaa8b0.tar.gz |
efi_loader: initialize return values in efi_uninstall_multiple_protocol_interfaces_int()
If the va_list we got handed over contains no protocols we must return
EFI_SUCCESS. However in that case the current code just returns
an unintialized value.
Fix that by setting the return value in the variable definition
Addresses-Coverity: CID 376195: ("Uninitialized variables (UNINIT)")
Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
Reviewed-by: Heinrich Schuchardt <heinrich.schuchardt@canonical.com>
-rw-r--r-- | lib/efi_loader/efi_boottime.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/efi_loader/efi_boottime.c b/lib/efi_loader/efi_boottime.c index a56021559b..253f9f75ef 100644 --- a/lib/efi_loader/efi_boottime.c +++ b/lib/efi_loader/efi_boottime.c @@ -2754,7 +2754,7 @@ efi_uninstall_multiple_protocol_interfaces_int(efi_handle_t handle, { const efi_guid_t *protocol; void *protocol_interface; - efi_status_t ret; + efi_status_t ret = EFI_SUCCESS; size_t i = 0; efi_va_list argptr_copy; |