Skip to content
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/types: copy tx recipient address #23376

Merged
merged 6 commits into from Oct 6, 2021

Conversation

aaronbuchwald
Copy link
Contributor

This PR creates a helper function CopyAddress to copy address pointers and uses it to address an outstanding TODO related to copying To addresses in transactions.

@aaronbuchwald
Copy link
Contributor Author

Wondering if it's cleaner to add a function common.CopyAddress(addr) instead

common/types.go Outdated Show resolved Hide resolved
@fjl
Copy link
Contributor

fjl commented Sep 7, 2021

We have discussed this and would rather have the function to copy an address pointer in core/types. The method is too specialized to be useful.

@fjl fjl changed the title Add helper for copying address pointers and address TODO core/types: copy tx recipient address Oct 6, 2021
@fjl fjl merged commit 4e599ee into ethereum:master Oct 6, 2021
@fjl fjl added this to the 1.10.10 milestone Oct 6, 2021
sidhujag pushed a commit to syscoin/go-ethereum that referenced this pull request Oct 6, 2021
This resolves a long-standing TODO. The point of copying the address is
to ensure that all data referenced by types.Transaction is independent of the
data passed into the constructor.

Co-authored-by: Felix Lange <fjl@twurst.com>
yongjun925 pushed a commit to DODOEX/go-ethereum that referenced this pull request Dec 3, 2022
This resolves a long-standing TODO. The point of copying the address is
to ensure that all data referenced by types.Transaction is independent of the
data passed into the constructor.

Co-authored-by: Felix Lange <fjl@twurst.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants