diff options
author | Heinrich Schuchardt <xypron.glpk@gmx.de> | 2022-06-11 05:22:08 +0000 |
---|---|---|
committer | Heinrich Schuchardt <xypron.glpk@gmx.de> | 2022-06-12 13:02:34 +0200 |
commit | 72fa9cd59edcf99cb32c05604d2a904018acd30a (patch) | |
tree | d2e3c21ced36d6bc1330d7860bce7e0d32415292 /lib/efi_loader/efi_bootmgr.c | |
parent | 178667b34bf0aa5312727eba6612b3500adad4a3 (diff) |
efi_loader: create boot options without file path
Allow the efidebug command to create boot options without file path, e.g.
efidebug boot add -b 0001 'short dev only' host 0:1 ''
efidebug boot add -B 0002 'long dev only' host 0:1 ''
Signed-off-by: Heinrich Schuchardt <xypron.glpk@gmx.de>
Diffstat (limited to 'lib/efi_loader/efi_bootmgr.c')
-rw-r--r-- | lib/efi_loader/efi_bootmgr.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/efi_loader/efi_bootmgr.c b/lib/efi_loader/efi_bootmgr.c index 9b65f34035..234073ecb7 100644 --- a/lib/efi_loader/efi_bootmgr.c +++ b/lib/efi_loader/efi_bootmgr.c @@ -46,7 +46,6 @@ struct efi_device_path *expand_media_path(struct efi_device_path *device_path) { struct efi_device_path *dp, *rem, *full_path; efi_handle_t handle; - efi_status_t ret; if (!device_path) return NULL; @@ -59,7 +58,7 @@ struct efi_device_path *expand_media_path(struct efi_device_path *device_path) dp = device_path; handle = efi_dp_find_obj(dp, &efi_simple_file_system_protocol_guid, &rem); - if (ret == EFI_SUCCESS) { + if (handle) { if (rem->type == DEVICE_PATH_TYPE_END) { dp = efi_dp_from_file(NULL, 0, "/EFI/BOOT/" BOOTEFI_NAME); |