Fix the storage of anchors in the state (#2563)

* Fix the storage of anchors in the state

* Bump database version
This commit is contained in:
Conrado Gouvea 2021-08-04 15:50:41 -03:00 committed by GitHub
parent 7ad5f1cd0a
commit 8747d6682e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -25,7 +25,7 @@ pub const MIN_TRANSPARENT_COINBASE_MATURITY: u32 = 100;
pub const MAX_BLOCK_REORG_HEIGHT: u32 = MIN_TRANSPARENT_COINBASE_MATURITY - 1;
/// The database format version, incremented each time the database format changes.
pub const DATABASE_FORMAT_VERSION: u32 = 6;
pub const DATABASE_FORMAT_VERSION: u32 = 7;
/// The maximum number of blocks to check for NU5 transactions,
/// before we assume we are on a pre-NU5 legacy chain.

View File

@ -347,8 +347,8 @@ impl FinalizedState {
}
// Compute the new anchors and index them
batch.zs_insert(sapling_anchors, height, sapling_note_commitment_tree.root());
batch.zs_insert(orchard_anchors, height, orchard_note_commitment_tree.root());
batch.zs_insert(sapling_anchors, sapling_note_commitment_tree.root(), ());
batch.zs_insert(orchard_anchors, orchard_note_commitment_tree.root(), ());
// Update the note commitment trees
if let Some(h) = finalized_tip_height {