diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 03:50:40 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 03:50:40 +0000 |
commit | fc53809803cd2bc2434e312b19a18fa36776da12 (patch) | |
tree | b4b43bd6538f51965ce32856e9c053d0f90919c8 /src/sysupdate/sysupdate-resource.c | |
parent | Adding upstream version 255.5. (diff) | |
download | systemd-fc53809803cd2bc2434e312b19a18fa36776da12.tar.xz systemd-fc53809803cd2bc2434e312b19a18fa36776da12.zip |
Adding upstream version 256.upstream/256
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/sysupdate/sysupdate-resource.c')
-rw-r--r-- | src/sysupdate/sysupdate-resource.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/src/sysupdate/sysupdate-resource.c b/src/sysupdate/sysupdate-resource.c index e4bdd88..5b7aee2 100644 --- a/src/sysupdate/sysupdate-resource.c +++ b/src/sysupdate/sysupdate-resource.c @@ -6,6 +6,7 @@ #include "alloc-util.h" #include "blockdev-util.h" +#include "build-path.h" #include "chase.h" #include "device-util.h" #include "devnum-util.h" @@ -300,7 +301,7 @@ static int download_manifest( /* Child */ const char *cmdline[] = { - "systemd-pull", + SYSTEMD_PULL_PATH, "raw", "--direct", /* just download the specified URL, don't download anything else */ "--verify", verify_signature ? "signature" : "no", /* verify the manifest file */ @@ -309,8 +310,8 @@ static int download_manifest( NULL }; - execv(pull_binary_path(), (char *const*) cmdline); - log_error_errno(errno, "Failed to execute %s tool: %m", pull_binary_path()); + r = invoke_callout_binary(SYSTEMD_PULL_PATH, (char *const*) cmdline); + log_error_errno(r, "Failed to execute %s tool: %m", SYSTEMD_PULL_PATH); _exit(EXIT_FAILURE); }; @@ -398,7 +399,7 @@ static int resource_load_from_web( if (p[0] == '\\') return log_error_errno(SYNTHETIC_ERRNO(EOPNOTSUPP), "File names with escapes not supported in manifest at line %zu, refusing.", line_nr); - r = unhexmem(p, 64, &h, &hlen); + r = unhexmem_full(p, 64, /* secure = */ false, &h, &hlen); if (r < 0) return log_error_errno(r, "Failed to parse digest at manifest line %zu, refusing.", line_nr); |