1
Fork 0
mirror of https://github.com/RGBCube/uutils-coreutils synced 2025-08-05 23:47:46 +00:00

mkdir: fixed permissions behavior with umask

- umask application more closely resembles gnu
This commit is contained in:
Pyokyeong Son 2022-02-18 07:52:38 +00:00
parent 6db5bf1652
commit b8c0a87f85

View file

@ -65,8 +65,8 @@ fn get_mode(matches: &ArgMatches, mode_had_minus_prefix: bool) -> Result<u32, St
Ok(new_mode) Ok(new_mode)
} }
None => { None => {
// If no mode argument is specified return the mode from umask // If no mode argument is specified return the mode derived from umask
Ok(mode::get_umask()) Ok(!mode::get_umask() & 0o0777)
} }
} }
} }