diff options
| author | Dan Engelbrecht <[email protected]> | 2024-08-15 11:55:30 +0200 |
|---|---|---|
| committer | GitHub Enterprise <[email protected]> | 2024-08-15 11:55:30 +0200 |
| commit | 4cec2ba76320e404452599c693982d32f29a9269 (patch) | |
| tree | 9108b046dd7b180210d82f443bbdb56dba583e68 /src/zenutil/basicfile.cpp | |
| parent | 5.5.4-pre1 (diff) | |
| download | zen-4cec2ba76320e404452599c693982d32f29a9269.tar.xz zen-4cec2ba76320e404452599c693982d32f29a9269.zip | |
adds more information in log when oplog rename/delete fails (#117)
* adds more information in log when oplog rename/delete fails
* warn if we fail to delete dropped directory
* close oplog storage file inside try/catch
* don't try to flush closed files
Diffstat (limited to 'src/zenutil/basicfile.cpp')
| -rw-r--r-- | src/zenutil/basicfile.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/zenutil/basicfile.cpp b/src/zenutil/basicfile.cpp index d837c2caf..266146ca1 100644 --- a/src/zenutil/basicfile.cpp +++ b/src/zenutil/basicfile.cpp @@ -359,6 +359,10 @@ BasicFile::WriteAll(IoBuffer Data, std::error_code& Ec) void BasicFile::Flush() { + if (m_FileHandle == nullptr) + { + return; + } #if ZEN_PLATFORM_WINDOWS FlushFileBuffers(m_FileHandle); #else |