mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-19 02:12:23 +00:00
core/vm: fix rebase issue
This commit is contained in:
parent
e64b41b205
commit
91016a7f6a
1 changed files with 8 additions and 8 deletions
|
|
@ -103,14 +103,6 @@ func (in *Interpreter) enforceRestrictions(op OpCode, operation operation, stack
|
||||||
// considered a revert-and-consume-all-gas operation except for
|
// considered a revert-and-consume-all-gas operation except for
|
||||||
// errExecutionReverted which means revert-and-keep-gas-left.
|
// errExecutionReverted which means revert-and-keep-gas-left.
|
||||||
func (in *Interpreter) Run(contract *Contract, input []byte) (ret []byte, err error) {
|
func (in *Interpreter) Run(contract *Contract, input []byte) (ret []byte, err error) {
|
||||||
// Increment the call depth which is restricted to 1024
|
|
||||||
in.evm.depth++
|
|
||||||
defer func() { in.evm.depth-- }()
|
|
||||||
|
|
||||||
// Reset the previous call's return data. It's unimportant to preserve the old buffer
|
|
||||||
// as every returning call will return new data anyway.
|
|
||||||
in.returnData = nil
|
|
||||||
|
|
||||||
if in.intPool == nil {
|
if in.intPool == nil {
|
||||||
in.intPool = poolOfIntPools.get()
|
in.intPool = poolOfIntPools.get()
|
||||||
defer func() {
|
defer func() {
|
||||||
|
|
@ -119,6 +111,14 @@ func (in *Interpreter) Run(contract *Contract, input []byte) (ret []byte, err er
|
||||||
}()
|
}()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Increment the call depth which is restricted to 1024
|
||||||
|
in.evm.depth++
|
||||||
|
defer func() { in.evm.depth-- }()
|
||||||
|
|
||||||
|
// Reset the previous call's return data. It's unimportant to preserve the old buffer
|
||||||
|
// as every returning call will return new data anyway.
|
||||||
|
in.returnData = nil
|
||||||
|
|
||||||
// Don't bother with the execution if there's no code.
|
// Don't bother with the execution if there's no code.
|
||||||
if len(contract.Code) == 0 {
|
if len(contract.Code) == 0 {
|
||||||
return nil, nil
|
return nil, nil
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue