diff options
author | Nick Johnson <arachnid@notdot.net> | 2017-01-17 19:19:50 +0800 |
---|---|---|
committer | Felix Lange <fjl@users.noreply.github.com> | 2017-01-17 19:19:50 +0800 |
commit | 17d92233d9e64b642fed9a992556f7ff7d6fda18 (patch) | |
tree | e655a85d9d31c3377aef21b441c8b2c44df0aeff /core/state/journal.go | |
parent | 26d385c18b5eb003d9a69ff618c78acbe594db44 (diff) | |
download | go-tangerine-17d92233d9e64b642fed9a992556f7ff7d6fda18.tar.gz go-tangerine-17d92233d9e64b642fed9a992556f7ff7d6fda18.tar.zst go-tangerine-17d92233d9e64b642fed9a992556f7ff7d6fda18.zip |
cmd/geth, core: add support for recording SHA3 preimages (#3543)
Diffstat (limited to 'core/state/journal.go')
-rw-r--r-- | core/state/journal.go | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/core/state/journal.go b/core/state/journal.go index d1e73e7d0..68d07fa03 100644 --- a/core/state/journal.go +++ b/core/state/journal.go @@ -67,6 +67,9 @@ type ( addLogChange struct { txhash common.Hash } + addPreimageChange struct { + hash common.Hash + } touchChange struct { account *common.Address prev bool @@ -127,3 +130,7 @@ func (ch addLogChange) undo(s *StateDB) { s.logs[ch.txhash] = logs[:len(logs)-1] } } + +func (ch addPreimageChange) undo(s *StateDB) { + delete(s.preimages, ch.hash) +} |