1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-07-29 12:07:46 +00:00

Update src/uu/cp/src/cp.rs

Co-authored-by: Sylvestre Ledru <sledru@mozilla.com>
This commit is contained in:
tommady 2023-10-12 10:42:52 +08:00 committed by GitHub
parent 7ea19c7c5d
commit 9be5583d36
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -1900,14 +1900,10 @@ fn handling_no_preserve_mode(options: &Options, org_mode: u32) -> u32 {
target_os = "macos-12",
target_os = "freebsd",
))]
const MODE_RW_UGO: u32 = (S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH) as u32;
#[cfg(any(
target_os = "android",
target_os = "macos",
target_os = "macos-12",
target_os = "freebsd",
))]
const S_IRWXUGO: u32 = (S_IRWXU | S_IRWXG | S_IRWXO) as u32;
{
const MODE_RW_UGO: u32 = (S_IRUSR | S_IWUSR | S_IRGRP | S_IWGRP | S_IROTH | S_IWOTH) as u32;
const S_IRWXUGO: u32 = (S_IRWXU | S_IRWXG | S_IRWXO) as u32;
}
match is_explicit_no_preserve_mode {
true => return MODE_RW_UGO,