This commit is contained in:
nym21
2025-11-20 20:35:54 +01:00
parent 8467e218ae
commit c8c62b504b
21 changed files with 432 additions and 405 deletions

View File

@@ -438,9 +438,9 @@ impl Vecs {
starting_indexes: brk_indexer::Indexes,
exit: &Exit,
) -> Result<Indexes> {
let idxs = self.compute_(indexer, starting_indexes, exit)?;
let indexes = self.compute_(indexer, starting_indexes, exit)?;
self.db.compact()?;
Ok(idxs)
Ok(indexes)
}
fn compute_(
@@ -460,13 +460,12 @@ impl Vecs {
&indexer.vecs.txinindex_to_outpoint,
|(txinindex, outpoint, ..)| {
if unlikely(outpoint.is_coinbase()) {
(txinindex, TxOutIndex::COINBASE)
} else {
let txoutindex = txindex_to_first_txoutindex
.read_unwrap(outpoint.txindex(), &txindex_to_first_txoutindex_reader)
+ outpoint.vout();
(txinindex, txoutindex)
return (txinindex, TxOutIndex::COINBASE);
}
let txoutindex = txindex_to_first_txoutindex
.read_unwrap(outpoint.txindex(), &txindex_to_first_txoutindex_reader)
+ outpoint.vout();
(txinindex, txoutindex)
},
exit,
)?;