mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-05-18 05:56:37 +00:00
eth: fix storageRangeAt for empty blocks (#18076)
This commit is contained in:
parent
252150918c
commit
49a7ee460e
1 changed files with 5 additions and 0 deletions
|
|
@ -795,6 +795,11 @@ func (api *PrivateDebugAPI) computeTxEnv(blockHash common.Hash, txIndex int, ree
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return nil, vm.Context{}, nil, err
|
return nil, vm.Context{}, nil, err
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if txIndex == 0 && len(block.Transactions()) == 0 {
|
||||||
|
return nil, vm.Context{}, statedb, nil
|
||||||
|
}
|
||||||
|
|
||||||
// Recompute transactions up to the target index.
|
// Recompute transactions up to the target index.
|
||||||
signer := types.MakeSigner(api.eth.blockchain.Config(), block.Number())
|
signer := types.MakeSigner(api.eth.blockchain.Config(), block.Number())
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue