From e415ca8274e68ee6ba44278aa14f6492ae20e4d5 Mon Sep 17 00:00:00 2001 From: Martin Ridgers Date: Wed, 8 Dec 2021 16:07:39 +0100 Subject: Added a missing file mode for a open() that creates a file --- zencore/filesystem.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'zencore/filesystem.cpp') diff --git a/zencore/filesystem.cpp b/zencore/filesystem.cpp index 4d37a7f20..0d378d56c 100644 --- a/zencore/filesystem.cpp +++ b/zencore/filesystem.cpp @@ -488,7 +488,7 @@ CopyFile(std::filesystem::path FromPath, std::filesystem::path ToPath, const Cop ScopedFd $From = { FromFd }; // To file - int ToFd = open(ToPath.c_str(), O_WRONLY|O_CREAT|O_EXCL|O_CLOEXEC); + int ToFd = open(ToPath.c_str(), O_WRONLY|O_CREAT|O_EXCL|O_CLOEXEC, 0644); if (ToFd < 0) { ThrowLastError("failed to create file {}"_format(ToPath)); -- cgit v1.2.3