diff options
author | Lennart Poettering <lennart@poettering.net> | 2024-10-15 15:36:06 +0200 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2024-10-15 18:21:04 +0200 |
commit | 518632ce1e24ee0a433ed8aff120861c870d1bb3 (patch) | |
tree | 8b31e89abb42eb530b3fa7c94ae01a57fe46ce58 /src/debug-generator/debug-generator.c | |
parent | dropin: use WRITE_STRING_FILE_MKDIR_0755 to create drop-in prefix path (diff) | |
download | systemd-518632ce1e24ee0a433ed8aff120861c870d1bb3.tar.xz systemd-518632ce1e24ee0a433ed8aff120861c870d1bb3.zip |
debug-generator: create prefix dir of generate unit file
Strictly speaking, it's more correct if we create the prefix path before
writing our unit file.
Diffstat (limited to '')
-rw-r--r-- | src/debug-generator/debug-generator.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/debug-generator/debug-generator.c b/src/debug-generator/debug-generator.c index 7637980689..98670a6c90 100644 --- a/src/debug-generator/debug-generator.c +++ b/src/debug-generator/debug-generator.c @@ -206,7 +206,7 @@ static int process_unit_credentials(const char *credentials_dir) { if (!p) return log_oom(); - r = write_string_file_atomic_label(p, d); + r = write_string_file_at_label(AT_FDCWD, p, d, WRITE_STRING_FILE_CREATE|WRITE_STRING_FILE_ATOMIC|WRITE_STRING_FILE_MKDIR_0755); if (r < 0) { log_warning_errno(r, "Failed to write unit file '%s' from credential '%s', ignoring: %m", unit, de->d_name); |