From 3497e9edc7766a60f41bdc913767619271b7c24e Mon Sep 17 00:00:00 2001 From: Dietmar Maurer Date: Wed, 29 May 2024 11:04:41 +0200 Subject: [PATCH] sys: use 0750 as default directory permissions Should not make a difference because default umask is 022 ... Signed-off-by: Dietmar Maurer --- proxmox-sys/src/fs/dir.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/proxmox-sys/src/fs/dir.rs b/proxmox-sys/src/fs/dir.rs index 403dce9f..c39b9fdf 100644 --- a/proxmox-sys/src/fs/dir.rs +++ b/proxmox-sys/src/fs/dir.rs @@ -19,7 +19,7 @@ pub fn create_dir>(path: P, options: CreateOptions) -> Result<(), #[allow(clippy::or_fun_call)] let mode: stat::Mode = options .perm - .unwrap_or(stat::Mode::from_bits_truncate(0o770)); + .unwrap_or(stat::Mode::from_bits_truncate(0o750)); let path = path.as_ref(); nix::unistd::mkdir(path, mode)?; @@ -43,7 +43,7 @@ pub fn ensure_dir_exists>( let mode: stat::Mode = options .perm - .unwrap_or(stat::Mode::from_bits_truncate(0o770)); + .unwrap_or(stat::Mode::from_bits_truncate(0o750)); let path = path.as_ref();