diff options
| author | Dan Engelbrecht <[email protected]> | 2022-03-22 12:17:41 +0100 |
|---|---|---|
| committer | Dan Engelbrecht <[email protected]> | 2022-03-31 11:28:33 +0200 |
| commit | 90ee5317a15cb51960b19b76e421725cf0e68dbe (patch) | |
| tree | b763a2698580b5da510b58b857551a018fd04718 | |
| parent | GC cleanup (diff) | |
| download | zen-90ee5317a15cb51960b19b76e421725cf0e68dbe.tar.xz zen-90ee5317a15cb51960b19b76e421725cf0e68dbe.zip | |
void copy of std::filesystem::path
| -rw-r--r-- | zenstore/basicfile.cpp | 4 | ||||
| -rw-r--r-- | zenstore/include/zenstore/basicfile.h | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/zenstore/basicfile.cpp b/zenstore/basicfile.cpp index 7d5b659c9..fd0c8a8f6 100644 --- a/zenstore/basicfile.cpp +++ b/zenstore/basicfile.cpp @@ -29,7 +29,7 @@ BasicFile::~BasicFile() } void -BasicFile::Open(std::filesystem::path FileName, bool IsCreate) +BasicFile::Open(const std::filesystem::path& FileName, bool IsCreate) { std::error_code Ec; Open(FileName, IsCreate, Ec); @@ -41,7 +41,7 @@ BasicFile::Open(std::filesystem::path FileName, bool IsCreate) } void -BasicFile::Open(std::filesystem::path FileName, bool IsCreate, std::error_code& Ec) +BasicFile::Open(const std::filesystem::path& FileName, bool IsCreate, std::error_code& Ec) { Ec.clear(); diff --git a/zenstore/include/zenstore/basicfile.h b/zenstore/include/zenstore/basicfile.h index 0837412de..30bb4ee8f 100644 --- a/zenstore/include/zenstore/basicfile.h +++ b/zenstore/include/zenstore/basicfile.h @@ -31,8 +31,8 @@ public: BasicFile(const BasicFile&) = delete; BasicFile& operator=(const BasicFile&) = delete; - void Open(std::filesystem::path FileName, bool IsCreate); - void Open(std::filesystem::path FileName, bool IsCreate, std::error_code& Ec); + void Open(const std::filesystem::path& FileName, bool IsCreate); + void Open(const std::filesystem::path& FileName, bool IsCreate, std::error_code& Ec); void Close(); void Read(void* Data, uint64_t Size, uint64_t FileOffset); void StreamFile(std::function<void(const void* Data, uint64_t Size)>&& ChunkFun); |