mirror of
https://github.com/systemd/systemd.git
synced 2025-01-12 13:18:14 +03:00
tmpfiles: fix check for figuring out whether to call chmod()
No need to call chown() if everything matches already.
This commit is contained in:
parent
59793c8f2e
commit
dc2335669a
@ -817,8 +817,8 @@ static int path_set_perms(Item *i, const char *path) {
|
||||
}
|
||||
}
|
||||
|
||||
if ((i->uid != st.st_uid || i->gid != st.st_gid) &&
|
||||
(i->uid_set || i->gid_set)) {
|
||||
if ((i->uid_set && i->uid != st.st_uid) ||
|
||||
(i->gid_set && i->gid != st.st_gid)) {
|
||||
log_debug("Changing \"%s\" to owner "UID_FMT":"GID_FMT,
|
||||
path,
|
||||
i->uid_set ? i->uid : UID_INVALID,
|
||||
|
Loading…
Reference in New Issue
Block a user