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.
This commit is contained in:
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user