diff options
| author | Dan Engelbrecht <[email protected]> | 2022-03-27 20:31:01 +0200 |
|---|---|---|
| committer | Dan Engelbrecht <[email protected]> | 2022-03-31 11:29:28 +0200 |
| commit | 71f53ef9404ceccf3583236260d4f192a251d3ee (patch) | |
| tree | 98491a1571d2dca00b682ea3fd7006c21242df55 /zenstore/compactcas.cpp | |
| parent | keep all block files open from start (diff) | |
| download | zen-71f53ef9404ceccf3583236260d4f192a251d3ee.tar.xz zen-71f53ef9404ceccf3583236260d4f192a251d3ee.zip | |
Remove redundant lock in BlockStoreFile
Diffstat (limited to 'zenstore/compactcas.cpp')
| -rw-r--r-- | zenstore/compactcas.cpp | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/zenstore/compactcas.cpp b/zenstore/compactcas.cpp index f7cfed47b..521546e10 100644 --- a/zenstore/compactcas.cpp +++ b/zenstore/compactcas.cpp @@ -1135,7 +1135,6 @@ CasContainerStrategy::CollectGarbage(GcContext& GcCtx) WriteOffset = 0; } - NewBlockFile->Write(Chunk.data(), Chunk.size(), WriteOffset); MovedBlockChunks.emplace( ChunkHash, @@ -1439,8 +1438,8 @@ CasContainerStrategy::OpenContainer(bool IsNewStore) std::filesystem::remove(Path); continue; } - auto BlockPath = GetBlockPath(m_BlocksBasePath, BlockIndex); - auto BlockFile = std::make_shared<BlockStoreFile>(BlockPath); + auto BlockPath = GetBlockPath(m_BlocksBasePath, BlockIndex); + auto BlockFile = std::make_shared<BlockStoreFile>(BlockPath); BlockFile->Open(); m_ChunkBlocks[BlockIndex] = BlockFile; } |