mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-25 06:06:44 +00:00
trie: use clear builtin
This commit is contained in:
parent
1791b95016
commit
8441958355
1 changed files with 1 additions and 1 deletions
|
|
@ -270,7 +270,7 @@ func (t *StateTrie) Commit(collectLeaf bool) (common.Hash, *trienode.NodeSet) {
|
||||||
if t.preimages != nil {
|
if t.preimages != nil {
|
||||||
t.preimages.InsertPreimage(t.secKeyCache)
|
t.preimages.InsertPreimage(t.secKeyCache)
|
||||||
}
|
}
|
||||||
t.secKeyCache = make(map[common.Hash][]byte)
|
clear(t.secKeyCache)
|
||||||
}
|
}
|
||||||
// Commit the trie and return its modified nodeset.
|
// Commit the trie and return its modified nodeset.
|
||||||
return t.trie.Commit(collectLeaf)
|
return t.trie.Commit(collectLeaf)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue