fix(tools): preserve controller command access #5582
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/5582"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from boykopovar/AnyPS5. Originally posted by JJenkx on 2026-10-14T00:15:38Z.
What
The controller-command helper writes through an atomic replacement. Its temporary file always had mode 0600 and the writer's ownership, so a privileged test helper replacing a game user's command file silently made future controller pulses unreadable to the game.
Retain an existing POSIX command file's permission mode. When the helper runs privileged, also retain its owner and group. Newly created files retain the existing private temporary-file defaults. Windows behavior is unchanged. Document the behavior in the usage guide.
Tested
2d14128a29ec, containing maind1670009fbfd: Linux 1,037 passed / 46 skipped; Windows 714 passed / 389 skipped. Expected skips remain unvalidated.Checklist
Imported from boykopovar/AnyPS5. Originally posted by adriadam10 on 2026-10-15T11:20:35Z.
Checked on the PR merged onto main:
pad_inputtests pass, and the mode-retention regression fails when the production change is reverted. The privileged owner/group test needs root and is skipped on my host; the code path (fchownbeforefchmodon the temp file, thenos.replace) reads correctly. Merging once the full Build is green.