Skip to content

Commit

Permalink
core/state: filter out nil trie for copy (#25575) (#340)
Browse files Browse the repository at this point in the history
Co-authored-by: rjl493456442 <[email protected]>
  • Loading branch information
minh-bq and rjl493456442 authored Aug 16, 2023
1 parent 5402fde commit 30fa13a
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions core/state/trie_prefetcher.go
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,9 @@ func (p *triePrefetcher) copy() *triePrefetcher {
// If the prefetcher is already a copy, duplicate the data
if p.fetches != nil {
for root, fetch := range p.fetches {
if fetch == nil {
continue
}
copy.fetches[root] = p.db.CopyTrie(fetch)
}
return copy
Expand Down

0 comments on commit 30fa13a

Please sign in to comment.