diff options
author | Lennart Poettering <lennart@poettering.net> | 2024-06-28 19:47:46 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2024-07-03 16:15:04 +0200 |
commit | b8ed6e22f01084530da8918a7da50c7327fa1987 (patch) | |
tree | 0a14a6d39c10b3809c53d212eb89d42beba18ffe /src/boot | |
parent | efi: don't non-chalantly drop const from memory buffer (diff) | |
download | systemd-b8ed6e22f01084530da8918a7da50c7327fa1987.tar.xz systemd-b8ed6e22f01084530da8918a7da50c7327fa1987.zip |
boot: indent error code path, but leave main code path unindented
Diffstat (limited to 'src/boot')
-rw-r--r-- | src/boot/efi/boot.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/src/boot/efi/boot.c b/src/boot/efi/boot.c index b3d9329926..aca34a5145 100644 --- a/src/boot/efi/boot.c +++ b/src/boot/efi/boot.c @@ -1664,9 +1664,16 @@ static void config_load_type1_entries( if (startswith(f->FileName, u"auto-")) continue; - err = file_read(entries_dir, f->FileName, 0, 0, &content, NULL); - if (err == EFI_SUCCESS) - boot_entry_add_type1(config, device, root_dir, u"\\loader\\entries", f->FileName, content, loaded_image_path); + err = file_read(entries_dir, + f->FileName, + /* offset= */ 0, + /* size= */ 0, + &content, + /* ret_size= */ NULL); + if (err != EFI_SUCCESS) + continue; + + boot_entry_add_type1(config, device, root_dir, u"\\loader\\entries", f->FileName, content, loaded_image_path); } } |