diff options
| author | Ophestra <cat@gensokyo.uk> | 2026-10-13 22:58:19 +0900 |
|---|---|---|
| committer | Ophestra <cat@gensokyo.uk> | 2026-10-13 22:58:19 +0900 |
| commit | fadb42ec8daeeb8a576582d274cd4aeb64e535c0 (patch) | |
| tree | 20db92adde637b3d1bc7a931d0551590e80456cf /internal/outcome/sptmpdir.go | |
| parent | 40e4c9031652731622315e778a9bcace6cea6cb3 (diff) | |
internal/system: skip superfluous chmod
A successful chmod clobbers acl mask, breaking the fast path. This
change also fixes the ACL race.
Signed-off-by: Ophestra <cat@gensokyo.uk>
Diffstat (limited to 'internal/outcome/sptmpdir.go')
| -rw-r--r-- | internal/outcome/sptmpdir.go | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/internal/outcome/sptmpdir.go b/internal/outcome/sptmpdir.go index 3acb069f..9a637f8b 100644 --- a/internal/outcome/sptmpdir.go +++ b/internal/outcome/sptmpdir.go @@ -19,9 +19,9 @@ type spTmpdirOp struct{} func (s spTmpdirOp) toSystem(state *outcomeStateSys) error { if state.Container.Flags&hst.FShareTmpdir != 0 { tmpdir, tmpdirInst := s.commonPaths(state.outcomeState) - state.sys.Ensure(tmpdir, 0700) + state.sys.Ensure(tmpdir, 0700, true) state.sys.UpdatePermType(system.User, tmpdir, acl.Execute) - state.sys.Ensure(tmpdirInst, 01700) + state.sys.Ensure(tmpdirInst, 01700, true) state.sys.UpdatePermType(system.User, tmpdirInst, acl.Read|acl.Write|acl.Execute) } return nil |
