summaryrefslogtreecommitdiff
path: root/src/sysusers/sysusers.c
diff options
context:
space:
mode:
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2021-12-17 16:06:51 +0100
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2021-12-17 18:47:53 +0100
commit47fb161e3a72c65071038eddbd84108504155b77 (patch)
treefb3f2e6de90c38746aa0a99dc2738d0d31becea7 /src/sysusers/sysusers.c
parent641e2124de6047e6010cd2925ea22fba29b25309 (diff)
downloadsystemd-47fb161e3a72c65071038eddbd84108504155b77.tar.gz
bootctl: write KERNEL_INSTALL_LAYOUT=bls and KERNEL_INSTALL_MACHINE_ID=…
This is a natural extension of d6bce6e224: if we are installing sd-boot, we want to use the sd-boot layout, so let's write the appropriate KERNEL_INSTALL_LAYOUT setting. Effectively, if we do 'booctl install', kernel-install will not autodetect the layout anymore. And 357376d0bb added support for KERNEL_INSTALL_MACHINE_ID. We need to support it here too. We both read it, so that we create the right directories, and also write it if it wasn't written yet and we created some directories using it, so that kernel-install that is executed later knows the machine-id that matches the directories we crated. The code is changed in some places to fail if we can't figure out the current status. When installing the boot loader it's probably better not to guess.
Diffstat (limited to 'src/sysusers/sysusers.c')
-rw-r--r--src/sysusers/sysusers.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/sysusers/sysusers.c b/src/sysusers/sysusers.c
index c3a9e54f3f..015e3a9ae4 100644
--- a/src/sysusers/sysusers.c
+++ b/src/sysusers/sysusers.c
@@ -269,10 +269,10 @@ static int make_backup(const char *target, const char *x) {
return -errno;
r = fopen_temporary_label(
- target, /* The path for which to the lookup the label */
+ target, /* The path for which to the look up the label */
x, /* Where we want the file actually to end up */
- &dst,
- &dst_tmp /* The temporary file we write to */);
+ &dst, /* The temporary file we write to */
+ &dst_tmp);
if (r < 0)
return r;