diff options
author | Yu Watanabe <watanabe.yu+github@gmail.com> | 2024-03-21 06:47:05 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-03-21 06:47:05 +0100 |
commit | 839dce5ecb8305f68cd9436b8936ee72204cc83f (patch) | |
tree | 54d2515b1faf1e5a155940abfa4eb545fb681f58 /src/kernel-install | |
parent | Merge pull request #31875 from ml-/docs-fix-socket-section (diff) | |
parent | shared/password-quality: inline iterator variable (diff) | |
download | systemd-839dce5ecb8305f68cd9436b8936ee72204cc83f.tar.xz systemd-839dce5ecb8305f68cd9436b8936ee72204cc83f.zip |
Merge pull request #31862 from keszybz/add-strdup_to-helper
Add strdup_to() helper
Diffstat (limited to 'src/kernel-install')
-rw-r--r-- | src/kernel-install/kernel-install.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/src/kernel-install/kernel-install.c b/src/kernel-install/kernel-install.c index cf1bb5c3af..6581e80656 100644 --- a/src/kernel-install/kernel-install.c +++ b/src/kernel-install/kernel-install.c @@ -151,37 +151,37 @@ static int context_copy(const Context *source, Context *ret) { return copy.rfd; } - r = strdup_or_null(source->layout_other, ©.layout_other); + r = strdup_to(©.layout_other, source->layout_other); if (r < 0) return r; - r = strdup_or_null(source->conf_root, ©.conf_root); + r = strdup_to(©.conf_root, source->conf_root); if (r < 0) return r; - r = strdup_or_null(source->boot_root, ©.boot_root); + r = strdup_to(©.boot_root, source->boot_root); if (r < 0) return r; - r = strdup_or_null(source->entry_token, ©.entry_token); + r = strdup_to(©.entry_token, source->entry_token); if (r < 0) return r; - r = strdup_or_null(source->entry_dir, ©.entry_dir); + r = strdup_to(©.entry_dir, source->entry_dir); if (r < 0) return r; - r = strdup_or_null(source->version, ©.version); + r = strdup_to(©.version, source->version); if (r < 0) return r; - r = strdup_or_null(source->kernel, ©.kernel); + r = strdup_to(©.kernel, source->kernel); if (r < 0) return r; r = strv_copy_unless_empty(source->initrds, ©.initrds); if (r < 0) return r; - r = strdup_or_null(source->initrd_generator, ©.initrd_generator); + r = strdup_to(©.initrd_generator, source->initrd_generator); if (r < 0) return r; - r = strdup_or_null(source->uki_generator, ©.uki_generator); + r = strdup_to(©.uki_generator, source->uki_generator); if (r < 0) return r; - r = strdup_or_null(source->staging_area, ©.staging_area); + r = strdup_to(©.staging_area, source->staging_area); if (r < 0) return r; r = strv_copy_unless_empty(source->plugins, ©.plugins); |