mirror of
https://github.com/kaspanet/kaspad.git
synced 2026-03-06 09:01:34 +00:00
Compare commits
2 Commits
v0.10.0-de
...
v0.10.1-rc
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
b405ea50e5 | ||
|
|
ccfe8a45dd |
@@ -59,6 +59,22 @@ func (bp *blockProcessor) setBlockStatusAfterBlockValidation(
|
||||
return nil
|
||||
}
|
||||
|
||||
func (bp *blockProcessor) updateVirtualAcceptanceDataAfterImportingPruningPoint(stagingArea *model.StagingArea) error {
|
||||
|
||||
_, virtualAcceptanceData, virtualMultiset, err :=
|
||||
bp.consensusStateManager.CalculatePastUTXOAndAcceptanceData(stagingArea, model.VirtualBlockHash)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
log.Debugf("Staging virtual acceptance data after importing the pruning point")
|
||||
bp.acceptanceDataStore.Stage(stagingArea, model.VirtualBlockHash, virtualAcceptanceData)
|
||||
|
||||
log.Debugf("Staging virtual multiset after importing the pruning point")
|
||||
bp.multisetStore.Stage(stagingArea, model.VirtualBlockHash, virtualMultiset)
|
||||
return nil
|
||||
}
|
||||
|
||||
func (bp *blockProcessor) validateAndInsertBlock(stagingArea *model.StagingArea, block *externalapi.DomainBlock,
|
||||
isPruningPoint bool) (*externalapi.BlockInsertionResult, error) {
|
||||
|
||||
@@ -102,6 +118,11 @@ func (bp *blockProcessor) validateAndInsertBlock(stagingArea *model.StagingArea,
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
} else {
|
||||
err := bp.updateVirtualAcceptanceDataAfterImportingPruningPoint(stagingArea)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@ const validCharacters = "0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrs
|
||||
const (
|
||||
appMajor uint = 0
|
||||
appMinor uint = 10
|
||||
appPatch uint = 0
|
||||
appPatch uint = 1
|
||||
)
|
||||
|
||||
// appBuild is defined as a variable so it can be overridden during the build
|
||||
|
||||
Reference in New Issue
Block a user