File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
ouroboros-consensus-cardano/src/unstable-cardano-tools/Cardano/Tools/DBAnalyser Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change @@ -444,10 +444,10 @@ storeLedgerStateAt slotNo ledgerAppMode env = do
444444 Left {} -> error " Unreachable, volatile tip MUST be in the LedgerDB"
445445 Right f -> pure f
446446 tbs <- LedgerDB. forkerReadTables frk (getBlockKeySets blk)
447- LedgerDB. forkerClose frk
448- case runExcept $ tickThenXApply OmitLedgerEvents ledgerCfg blk (oldLedger `withLedgerTables` tbs) of
447+ r <- case runExcept $ tickThenXApply OmitLedgerEvents ledgerCfg blk (oldLedger `withLedgerTables` tbs) of
449448 Right newLedger -> do
450- LedgerDB. push internal newLedger
449+ LedgerDB. forkerPush frk newLedger
450+ IOLike. atomically $ LedgerDB. forkerCommit frk
451451 when (blockSlot blk >= slotNo) storeLedgerState
452452 when (blockSlot blk > slotNo) $ issueWarning blk
453453 when ((unBlockNo $ blockNo blk) `mod` 1000 == 0 ) $ reportProgress blk
@@ -457,6 +457,8 @@ storeLedgerStateAt slotNo ledgerAppMode env = do
457457 traceWith tracer $ LedgerErrorEvent (blockPoint blk) err
458458 storeLedgerState
459459 pure (Stop , () )
460+ LedgerDB. forkerClose frk
461+ pure r
460462
461463 tickThenXApply = case ledgerAppMode of
462464 LedgerReapply -> pure ...: tickThenReapply
You can’t perform that action at this time.
0 commit comments