summaryrefslogtreecommitdiff
path: root/src/portable
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2023-03-03 11:27:42 +0100
committerLennart Poettering <lennart@poettering.net>2023-03-03 13:44:12 +0100
commit23e208e742855d28bb3b02db2093e5a8ffc102f6 (patch)
tree28f01cfd86d6cf3dd3714f17997dde19d82de13f /src/portable
parent16a9ad557de7173c182e9587a9cc0ca146293ec8 (diff)
downloadsystemd-23e208e742855d28bb3b02db2093e5a8ffc102f6.tar.gz
tmpfile-util: teach link_tmpfile() to optionally replace files
Diffstat (limited to 'src/portable')
-rw-r--r--src/portable/portable.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/portable/portable.c b/src/portable/portable.c
index 7811833fac..377e1a9937 100644
--- a/src/portable/portable.c
+++ b/src/portable/portable.c
@@ -1188,7 +1188,7 @@ static int attach_unit_file(
if (fchmod(fd, 0644) < 0)
return log_debug_errno(errno, "Failed to change unit file access mode for '%s': %m", path);
- r = link_tmpfile(fd, tmp, path);
+ r = link_tmpfile(fd, tmp, path, /* replace= */ false);
if (r < 0)
return log_debug_errno(r, "Failed to install unit file '%s': %m", path);