summaryrefslogtreecommitdiff
path: root/src/boot/bootctl.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/boot/bootctl.c')
-rw-r--r--src/boot/bootctl.c10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/boot/bootctl.c b/src/boot/bootctl.c
index e77ab3f850..d53f8b2a6f 100644
--- a/src/boot/bootctl.c
+++ b/src/boot/bootctl.c
@@ -439,9 +439,12 @@ static int status_variables(void) {
for (j = 0; j < n_order; j++)
if (options[i] == order[j])
- continue;
+ goto next_option;
print_efi_option(options[i], false);
+
+ next_option:
+ continue;
}
return 0;
@@ -618,7 +621,8 @@ static const char *efi_subdirs[] = {
"EFI/systemd",
"EFI/BOOT",
"loader",
- "loader/entries"
+ "loader/entries",
+ NULL
};
static int create_dirs(const char *esp_path) {
@@ -914,7 +918,7 @@ static int remove_binaries(const char *esp_path) {
if (q < 0 && r == 0)
r = q;
- for (i = ELEMENTSOF(efi_subdirs); i > 0; i--) {
+ for (i = ELEMENTSOF(efi_subdirs)-1; i > 0; i--) {
q = rmdir_one(esp_path, efi_subdirs[i-1]);
if (q < 0 && r == 0)
r = q;