summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Jones <pjones@redhat.com>2017-10-23 15:29:45 -0400
committerPeter Jones <pmjones@gmail.com>2018-03-12 16:21:43 -0400
commit1a44dbb8be12ef2a06d73b8eec07ac0acff27e68 (patch)
tree0e57e3ef433a3dac41cb519ecda2df1b66ee7b78
parent3832428e0241b72af27afa7cb0ac9c85410bb2e7 (diff)
downloadefi-boot-shim-1a44dbb8be12ef2a06d73b8eec07ac0acff27e68.tar.gz
efi-boot-shim-1a44dbb8be12ef2a06d73b8eec07ac0acff27e68.zip
Rename generate_path() because we have 2 of it.
Signed-off-by: Peter Jones <pjones@redhat.com>
-rw-r--r--shim.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/shim.c b/shim.c
index 6d777d86..d4d47476 100644
--- a/shim.c
+++ b/shim.c
@@ -1590,8 +1590,9 @@ error:
* Generate the path of an executable given shim's path and the name
* of the executable
*/
-static EFI_STATUS generate_path(EFI_LOADED_IMAGE *li, CHAR16 *ImagePath,
- CHAR16 **PathName)
+static EFI_STATUS generate_path_from_image_path(EFI_LOADED_IMAGE *li,
+ CHAR16 *ImagePath,
+ CHAR16 **PathName)
{
EFI_DEVICE_PATH *devpath;
unsigned int i;
@@ -1895,10 +1896,10 @@ EFI_STATUS start_image(EFI_HANDLE image_handle, CHAR16 *ImagePath)
/*
* Build a new path from the existing one plus the executable name
*/
- efi_status = generate_path(li, ImagePath, &PathName);
-
- if (efi_status != EFI_SUCCESS) {
- perror(L"Unable to generate path %s: %r\n", ImagePath, efi_status);
+ efi_status = generate_path_from_image_path(li, ImagePath, &PathName);
+ if (EFI_ERROR(efi_status)) {
+ perror(L"Unable to generate path %s: %r\n", ImagePath,
+ efi_status);
goto done;
}