From: Lennart Poettering Date: Sun, 9 Feb 2025 06:38:41 +0000 (+0100) Subject: bootctl: improve output regarding random seed if we cannot access ESP X-Git-Tag: v258-rc1~1379 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=f90efd2d13aac38417b2e0e08068fc0fba2da72a;p=thirdparty%2Fsystemd.git bootctl: improve output regarding random seed if we cannot access ESP --- diff --git a/src/bootctl/bootctl-status.c b/src/bootctl/bootctl-status.c index 40642d3c1c4..75ffb9fdba0 100644 --- a/src/bootctl/bootctl-status.c +++ b/src/bootctl/bootctl-status.c @@ -534,8 +534,11 @@ int verb_status(int argc, char *argv[], void *userdata) { if (!p) return log_oom(); - have = access(p, F_OK) >= 0; - printf(" Exists: %s\n", yes_no(have)); + r = access(p, F_OK); + if (r < 0 && errno != ENOENT) + printf(" Exists: Can't access %s (%m)\n", p); + else + printf(" Exists: %s\n", yes_no(r >= 0)); } printf("\n");