mirror of
https://github.com/RGBCube/uutils-coreutils
synced 2025-08-02 14:07:46 +00:00
test/mkdir: made umask variable mode_t
This commit is contained in:
parent
553c22d33d
commit
fe9e9e6689
1 changed files with 2 additions and 2 deletions
|
@ -2,7 +2,7 @@ use crate::common::util::*;
|
||||||
#[cfg(not(windows))]
|
#[cfg(not(windows))]
|
||||||
use std::os::unix::fs::PermissionsExt;
|
use std::os::unix::fs::PermissionsExt;
|
||||||
extern crate libc;
|
extern crate libc;
|
||||||
use self::libc::umask;
|
use self::libc::{umask, mode_t};
|
||||||
|
|
||||||
static TEST_DIR1: &str = "mkdir_test1";
|
static TEST_DIR1: &str = "mkdir_test1";
|
||||||
static TEST_DIR2: &str = "mkdir_test2";
|
static TEST_DIR2: &str = "mkdir_test2";
|
||||||
|
@ -107,7 +107,7 @@ fn test_multi_symbolic() {
|
||||||
#[test]
|
#[test]
|
||||||
#[cfg(not(windows))]
|
#[cfg(not(windows))]
|
||||||
fn test_umask_compliance() {
|
fn test_umask_compliance() {
|
||||||
fn test_single_case(umask_set: u32) {
|
fn test_single_case(umask_set: mode_t) {
|
||||||
let (at, mut ucmd) = at_and_ucmd!();
|
let (at, mut ucmd) = at_and_ucmd!();
|
||||||
|
|
||||||
let original_umask = unsafe { umask(umask_set) };
|
let original_umask = unsafe { umask(umask_set) };
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue