Remove recover from settle

This commit is contained in:
Jerry 2023-05-01 15:32:20 -07:00
parent a093c4e7df
commit 82390264bc
No known key found for this signature in database
GPG key ID: 5B33FA23CB103211

View file

@ -175,17 +175,6 @@ func (task *ExecutionTask) Dependencies() []int {
}
func (task *ExecutionTask) Settle() {
defer func() {
if r := recover(); r != nil {
// In some rare cases, ApplyMVWriteSet will panic due to an index out of range error when calculating the
// address hash in sha3 module. Recover from panic and continue the execution.
// After recovery, block receipts or merckle root will be incorrect, but this is fine, because the block
// will be rejected and re-synced.
log.Info("Recovered from error", "Error:", r)
return
}
}()
task.finalStateDB.Prepare(task.tx.Hash(), task.index)
coinbaseBalance := task.finalStateDB.GetBalance(task.coinbase)