diff options
| author | Dan Engelbrecht <[email protected]> | 2024-06-14 22:12:57 +0200 |
|---|---|---|
| committer | GitHub Enterprise <[email protected]> | 2024-06-14 22:12:57 +0200 |
| commit | ee5fcbce34eaef87ffced2a993c8443af4af4fe2 (patch) | |
| tree | 7eeb7df5c48d11a2653e1536f39f4f0bf17f0b53 /src/zenstore/blockstore.cpp | |
| parent | workspace share path hardening (#95) (diff) | |
| download | zen-ee5fcbce34eaef87ffced2a993c8443af4af4fe2.tar.xz zen-ee5fcbce34eaef87ffced2a993c8443af4af4fe2.zip | |
don't assert that we have moved bytes if source block is zero size (#97)
* don't assert that we have moved bytes if source block is zero size
* handle invalid session ids gracefully
Diffstat (limited to 'src/zenstore/blockstore.cpp')
| -rw-r--r-- | src/zenstore/blockstore.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/zenstore/blockstore.cpp b/src/zenstore/blockstore.cpp index 6e289409c..4b650e2d5 100644 --- a/src/zenstore/blockstore.cpp +++ b/src/zenstore/blockstore.cpp @@ -1382,7 +1382,8 @@ BlockStore::CompactBlocks(const BlockStoreCompactState& CompactState, MovedSize += NewBlockSize; NewBlockFile = nullptr; - ZEN_ASSERT(!MovedChunks.empty() || RemovedSize > 0); // We should not have a new block if we haven't moved anything + ZEN_ASSERT(!MovedChunks.empty() || + (RemovedSize > 0 || OldBlockSize == 0)); // We should not have a new block if we haven't moved anything ZEN_INFO("{}wrote block {} ({})", LogPrefix, |