From cf3ac07a7e000f949cfe29895b543939e94e7d7f Mon Sep 17 00:00:00 2001 From: gingerBill Date: Thu, 19 Feb 2026 14:00:38 +0000 Subject: [PATCH] Fix `copy_directory_all` --- core/os/dir.odin | 4 ++-- core/os/temp_file.odin | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/core/os/dir.odin b/core/os/dir.odin index 2548480c2..02dcb87af 100644 --- a/core/os/dir.odin +++ b/core/os/dir.odin @@ -208,7 +208,7 @@ read_directory_iterator :: proc(it: ^Read_Directory_Iterator) -> (fi: File_Info, } // Recursively copies a directory to `dst` from `src` -copy_directory_all :: proc(dst, src: string, dst_perm := 0o755) -> Error { +copy_directory_all :: proc(dst, src: string, dst_perm := Permissions_Default) -> Error { when #defined(_copy_directory_all_native) { return _copy_directory_all_native(dst, src, dst_perm) } else { @@ -217,7 +217,7 @@ copy_directory_all :: proc(dst, src: string, dst_perm := 0o755) -> Error { } @(private) -_copy_directory_all :: proc(dst, src: string, dst_perm := 0o755) -> Error { +_copy_directory_all :: proc(dst, src: string, dst_perm := Permissions_Default) -> Error { err := make_directory(dst, dst_perm) if err != nil && err != .Exist { return err diff --git a/core/os/temp_file.odin b/core/os/temp_file.odin index be10eb22e..9068b6590 100644 --- a/core/os/temp_file.odin +++ b/core/os/temp_file.odin @@ -58,7 +58,7 @@ make_directory_temp :: proc(dir, pattern: string, allocator: runtime.Allocator) attempts := 0 for { name := concatenate_strings_from_buffer(name_buf[:], prefix, random_string(rand_buf[:]), suffix) - err = make_directory(name, 0o700) + err = make_directory(name) if err == nil { return clone_string(name, allocator) }