[systemd-commits] 2 commits - src/shared units/systemd-tmpfiles-clean.service.in
Lennart Poettering
lennart at kemper.freedesktop.org
Thu Jun 19 15:22:11 PDT 2014
src/shared/copy.c | 3 ++-
units/systemd-tmpfiles-clean.service.in | 5 +++--
2 files changed, 5 insertions(+), 3 deletions(-)
New commits:
commit 2c455af4c765463c75df79acba34d2347c03cbff
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Jun 20 00:20:35 2014 +0200
copy: don't eat up error from chown()/chmod()
The idea was to not fail on, nor to ignore errors from chown()/chmod(),
but to proceed and simply return the most recent error...
diff --git a/src/shared/copy.c b/src/shared/copy.c
index 867e49b..7c3fab6 100644
--- a/src/shared/copy.c
+++ b/src/shared/copy.c
@@ -179,6 +179,8 @@ static int fd_copy_directory(int df, const char *from, const struct stat *st, in
if (fdt < 0)
return -errno;
+ r = 0;
+
if (created) {
if (fchown(fdt, st->st_uid, st->st_gid) < 0)
r = -errno;
@@ -187,7 +189,6 @@ static int fd_copy_directory(int df, const char *from, const struct stat *st, in
r = -errno;
}
- r = 0;
FOREACH_DIRENT(de, d, return -errno) {
struct stat buf;
int q;
commit 497d1986c13032f1ef8f4592bb7ed8d3aa321a47
Author: Lennart Poettering <lennart at poettering.net>
Date: Fri Jun 20 00:15:39 2014 +0200
units: order systemd-tmpfiles-clean.service after time-sync.target
That way, on systems lacking an RTC we don't false start removing aged
files too early.
diff --git a/units/systemd-tmpfiles-clean.service.in b/units/systemd-tmpfiles-clean.service.in
index 5946fcd..31b2378 100644
--- a/units/systemd-tmpfiles-clean.service.in
+++ b/units/systemd-tmpfiles-clean.service.in
@@ -9,8 +9,9 @@
Description=Cleanup of Temporary Directories
Documentation=man:tmpfiles.d(5) man:systemd-tmpfiles(8)
DefaultDependencies=no
-After=systemd-readahead-collect.service systemd-readahead-replay.service local-fs.target
-Before=sysinit.target shutdown.target
+Conflicts=shutdown.target
+After=systemd-readahead-collect.service systemd-readahead-replay.service local-fs.target time-sync.target
+Before=shutdown.target
[Service]
Type=oneshot
More information about the systemd-commits
mailing list