mirror of
https://github.com/nspcc-dev/neo-go.git
synced 2024-12-23 13:41:37 +00:00
core: stop storage items reset after any seek error
This commit is contained in:
parent
bfe7aeae7b
commit
ecda07736e
1 changed files with 2 additions and 1 deletions
|
@ -796,13 +796,14 @@ func (bc *Blockchain) resetStateInternal(height uint32, stage stateChangeStage)
|
|||
err = stackitem.DeserializeConvertible(v, cs)
|
||||
if err != nil {
|
||||
seekErr = fmt.Errorf("failed to deserialize contract %s state: %w", hash.StringLE(), seekErr)
|
||||
return false
|
||||
}
|
||||
cache.PutContractID(cs.ID, hash)
|
||||
cnt++
|
||||
contractIDsCnt++
|
||||
}
|
||||
|
||||
return seekErr == nil
|
||||
return true
|
||||
})
|
||||
if seekErr != nil {
|
||||
return fmt.Errorf("failed to reset contract contract storage items and IDs: %w", seekErr)
|
||||
|
|
Loading…
Reference in a new issue