New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

core/vm: implement RETURNDATA metropolis opcodes #14981

Merged
merged 3 commits into from Aug 16, 2017

Conversation

Projects
None yet
3 participants
@karalabe
Member

karalabe commented Aug 16, 2017

Implements ethereum/EIPs#211.

obscuren and others added some commits Aug 16, 2017

@karalabe karalabe added this to the 1.7.0 milestone Aug 16, 2017

@karalabe karalabe added the metropolis label Aug 16, 2017

@karalabe karalabe requested a review from holiman Aug 16, 2017

@karalabe karalabe referenced this pull request Aug 16, 2017

Closed

Metropolis aggregate PR #14726

7 of 8 tasks complete
@@ -113,6 +114,10 @@ func (in *Interpreter) Run(snapshot int, contract *Contract, input []byte) (ret
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

This comment has been minimized.

@holiman

holiman Aug 16, 2017

Contributor

Minor nitpick, it's not only "unimportant to preserve the old buffer", it's required to clear the buffer here - otherwise a child-call could access the returndata from a parent context.

@holiman

holiman Aug 16, 2017

Contributor

Minor nitpick, it's not only "unimportant to preserve the old buffer", it's required to clear the buffer here - otherwise a child-call could access the returndata from a parent context.

@karalabe

This comment has been minimized.

Show comment
Hide comment
@karalabe

karalabe Aug 16, 2017

Member
Member

karalabe commented Aug 16, 2017

@holiman

This comment has been minimized.

Show comment
Hide comment
@holiman

holiman Aug 16, 2017

Contributor

Ah, yeah that makes more sense, thanks

Contributor

holiman commented Aug 16, 2017

Ah, yeah that makes more sense, thanks

@karalabe karalabe merged commit 0b978f9 into ethereum:master Aug 16, 2017

1 of 3 checks passed

continuous-integration/travis-ci/pr The Travis CI build failed
Details
continuous-integration/appveyor/pr Waiting for AppVeyor build to complete
Details
commit-message-check/gitcop All commit messages are valid
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment