Skip to content

Conversation

@my4ng
Copy link
Contributor

@my4ng my4ng commented Feb 10, 2026

This fixes #10787 by granting temporary u+wx permission when building directory while preserving attributes. The true permission is set dirs_needing_permissions later.

Add test case for the issue.

@my4ng my4ng changed the title fix(cp): add temporary write perm to built dirs fix(cp): add temporary write/exec perm to built dirs Feb 10, 2026
@github-actions
Copy link

GNU testsuite comparison:

Skip an intermittent issue tests/shuf/shuf-reservoir (fails in this run but passes in the 'main' branch)
Skip an intermittent issue tests/sort/sort-stale-thread-mem (fails in this run but passes in the 'main' branch)
Congrats! The gnu test tests/pr/bounded-memory is no longer failing!

@github-actions
Copy link

GNU testsuite comparison:

GNU test failed: tests/pr/bounded-memory. tests/pr/bounded-memory is passing on 'main'. Maybe you have to rebase?

@ChrisDryden
Copy link
Collaborator

I ran an strace on the example and saw that that the reference implementation copies the files in the reverse order but when I was trying to see with a bunch of different permission sets it didn't seems to have any deviation in output so it looks like its correct

.arg("test-dir-copy")
.succeeds();

assert_eq!(at.metadata("test-dir").permissions().mode() & 0o777, 0o500);
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think the goal here would be to check the permissions of the test-dir-copy not the test-dir right?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep should have checked test-dir-copy instead, my bad

@my4ng
Copy link
Contributor Author

my4ng commented Feb 13, 2026

superseded by #10904.

@my4ng my4ng closed this Feb 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

cp -a still fails with readonly directories (follow-up to #7961)

3 participants