diff options
| author | Dan Engelbrecht <[email protected]> | 2024-08-20 14:14:42 +0200 |
|---|---|---|
| committer | GitHub Enterprise <[email protected]> | 2024-08-20 14:14:42 +0200 |
| commit | e643ca2e62ce5ecd2604afa51cb4d131bc76afa2 (patch) | |
| tree | 6a55b4fe112b159849c16f41b1910531f65eb285 | |
| parent | demote project store access time read fail to warning (#127) (diff) | |
| download | zen-e643ca2e62ce5ecd2604afa51cb4d131bc76afa2.tar.xz zen-e643ca2e62ce5ecd2604afa51cb4d131bc76afa2.zip | |
close payload file if size mismatch for file cas (#128)
| -rw-r--r-- | CHANGELOG.md | 1 | ||||
| -rw-r--r-- | src/zenstore/filecas.cpp | 4 |
2 files changed, 3 insertions, 2 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index 894be2fe2..5960d922a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,6 +4,7 @@ - Bugfix: If we fail to get information on a cache chunk for a partial chunk request - treat it as a cache miss - Bugfix: Set last GC time when we skip GC due to low disk space to avoid spam-running GC - Bugfix: Make sure we lock project and verify directory exists before trying to iterate to find oplogs +- Bugfix: Failure to get size or if size mismatch of a file in filecas now results in overwrite without error report ## 5.5.4 - Feature: Added new option to zenserver for GC V2 diff --git a/src/zenstore/filecas.cpp b/src/zenstore/filecas.cpp index b3cdafd4e..48177ac9e 100644 --- a/src/zenstore/filecas.cpp +++ b/src/zenstore/filecas.cpp @@ -601,10 +601,10 @@ FileCasStrategy::InsertChunkData(const void* const ChunkData, const size_t Chunk Name.ShardedPath.ToUtf8(), ChunkSize, FileSize); + PayloadFile.Close(); } } - - if ((hRes != HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND)) && (hRes != HRESULT_FROM_WIN32(ERROR_PATH_NOT_FOUND))) + else if ((hRes != HRESULT_FROM_WIN32(ERROR_FILE_NOT_FOUND)) && (hRes != HRESULT_FROM_WIN32(ERROR_PATH_NOT_FOUND))) { ZEN_WARN("Unexpected error code when opening shard file for read: {:#x}", uint32_t(hRes)); } |