diff options
| author | Dan Engelbrecht <[email protected]> | 2022-05-09 13:51:52 +0200 |
|---|---|---|
| committer | GitHub <[email protected]> | 2022-05-09 13:51:52 +0200 |
| commit | 8265ceec30d7a8cc862928507c6eed12191e5ef5 (patch) | |
| tree | de40771ed96d013992eb0c502317ea76940827fe /zenstore/basicfile.cpp | |
| parent | Initialize upstream apply in background thread (#88) (diff) | |
| parent | Make sure blockstore owner and block store state does not get out of sync whe... (diff) | |
| download | zen-1.0.1.3.tar.xz zen-1.0.1.3.zip | |
Merge pull request #91 from EpicGames/de/block-store-gc-bugv1.0.1.3
Make sure block store owner and block store state does not get out of sync when fetching a chunk
Diffstat (limited to 'zenstore/basicfile.cpp')
| -rw-r--r-- | zenstore/basicfile.cpp | 25 |
1 files changed, 0 insertions, 25 deletions
diff --git a/zenstore/basicfile.cpp b/zenstore/basicfile.cpp index 8eb172a1c..e5a2adc41 100644 --- a/zenstore/basicfile.cpp +++ b/zenstore/basicfile.cpp @@ -373,31 +373,6 @@ BasicFile::SetFileSize(uint64_t FileSize) #endif } -void -BasicFile::MarkAsDeleteOnClose(std::error_code& Ec) -{ - Ec.clear(); -#if ZEN_PLATFORM_WINDOWS - FILE_DISPOSITION_INFO Fdi{}; - Fdi.DeleteFile = TRUE; - BOOL Success = SetFileInformationByHandle(m_FileHandle, FileDispositionInfo, &Fdi, sizeof Fdi); - if (!Success) - { - Ec = MakeErrorCodeFromLastError(); - } -#elif ZEN_PLATFORM_LINUX || ZEN_PLATFORM_MAC - std::filesystem::path SourcePath = PathFromHandle(m_FileHandle); - if (unlink(SourcePath.c_str()) < 0) - { - int UnlinkError = zen::GetLastError(); - if (UnlinkError != ENOENT) - { - Ec = MakeErrorCode(UnlinkError); - } - } -#endif -} - void* BasicFile::Detach() { |