-
-
Notifications
You must be signed in to change notification settings - Fork 1.8k
fix(cp): add temporary write/exec perm to built dirs #10859
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
GNU testsuite comparison: |
|
GNU testsuite comparison: |
|
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 |
tests/by-util/test_cp.rs
Outdated
| .arg("test-dir-copy") | ||
| .succeeds(); | ||
|
|
||
| assert_eq!(at.metadata("test-dir").permissions().mode() & 0o777, 0o500); |
There was a problem hiding this comment.
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?
There was a problem hiding this comment.
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
|
superseded by #10904. |
This fixes #10787 by granting temporary u+wx permission when building directory while preserving attributes. The true permission is set
dirs_needing_permissionslater.Add test case for the issue.