aboutsummaryrefslogtreecommitdiff
path: root/src/zencore/iobuffer.cpp
diff options
context:
space:
mode:
authorStefan Boberg <[email protected]>2023-05-15 17:58:46 +0200
committerGitHub <[email protected]>2023-05-15 17:58:46 +0200
commit121d3fb3d9835ec78a1de7f268e79bf79cbf5865 (patch)
tree2f9c9f5c6a1d3ed41a9f3009104002bc5dd94bb8 /src/zencore/iobuffer.cpp
parentall threads should be named (#304) (diff)
downloadzen-121d3fb3d9835ec78a1de7f268e79bf79cbf5865.tar.xz
zen-121d3fb3d9835ec78a1de7f268e79bf79cbf5865.zip
Remove ATL header usage (#306)
ATL has been used here and there as a convenience. Given that this is a legacy component and not always something which gets installed along with the compiler we hereby remove the dependency altogether in favour of our own simple wrappers
Diffstat (limited to 'src/zencore/iobuffer.cpp')
-rw-r--r--src/zencore/iobuffer.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/zencore/iobuffer.cpp b/src/zencore/iobuffer.cpp
index 96653c670..3aca0cfa7 100644
--- a/src/zencore/iobuffer.cpp
+++ b/src/zencore/iobuffer.cpp
@@ -21,7 +21,7 @@ ZEN_THIRD_PARTY_INCLUDES_END
#endif
#if ZEN_PLATFORM_WINDOWS
-# include <atlfile.h>
+# include <zencore/windows.h>
#else
# include <sys/stat.h>
# include <sys/mman.h>
@@ -555,7 +555,7 @@ IoBufferBuilder::MakeFromFile(const std::filesystem::path& FileName, uint64_t Of
uint64_t FileSize;
#if ZEN_PLATFORM_WINDOWS
- CAtlFile DataFile;
+ windows::FileHandle DataFile;
DWORD ShareOptions = FILE_SHARE_DELETE | FILE_SHARE_WRITE | FILE_SHARE_DELETE | FILE_SHARE_READ;
HRESULT hRes = DataFile.Create(FileName.c_str(), GENERIC_READ, ShareOptions, OPEN_EXISTING);
@@ -620,7 +620,7 @@ IoBufferBuilder::MakeFromTemporaryFile(const std::filesystem::path& FileName)
void* Handle;
#if ZEN_PLATFORM_WINDOWS
- CAtlFile DataFile;
+ windows::FileHandle DataFile;
// We need to open with DELETE since this is used for the case
// when a file has been written to a staging directory, and is going