tmpfiles: age root-owned read-only files, by default (#7917)
[zj: The note in NEWS was added in 82c8e3e650
and released as part of systemd-237.]
This commit is contained in:
parent
b8e2400586
commit
a083b4875e
|
@ -568,12 +568,6 @@ static int dir_cleanup(
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Do not delete read-only files owned by root */
|
|
||||||
if (s.st_uid == 0 && !(s.st_mode & S_IWUSR)) {
|
|
||||||
log_debug("Ignoring \"%s/%s\": read-only and owner by root.", p, dent->d_name);
|
|
||||||
continue;
|
|
||||||
}
|
|
||||||
|
|
||||||
sub_path = strjoin(p, "/", dent->d_name);
|
sub_path = strjoin(p, "/", dent->d_name);
|
||||||
if (!sub_path) {
|
if (!sub_path) {
|
||||||
r = log_oom();
|
r = log_oom();
|
||||||
|
|
Loading…
Reference in New Issue