diff options
-rw-r--r-- | ports/unix/guts/mkdirat.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ports/unix/guts/mkdirat.c b/ports/unix/guts/mkdirat.c index dceedeb..5f80b50 100644 --- a/ports/unix/guts/mkdirat.c +++ b/ports/unix/guts/mkdirat.c @@ -6,13 +6,13 @@ * wrap_mkdirat(int dirfd, const char *path, mode_t mode) { * int rc = -1; */ + /* mask out mode bits appropriately */ + mode = mode & ~pseudo_umask; #ifdef PSEUDO_NO_REAL_AT_FUNCTIONS if (dirfd != AT_FDCWD) { errno = ENOSYS; return -1; } - /* mask out mode bits appropriately */ - mode = mode & ~pseudo_umask; rc = real_mkdir(path, PSEUDO_FS_MODE(mode, 1)); #else |