From 9b9143b14ba135ae8ea3d0f8d49a591d9ec0e3a8 Mon Sep 17 00:00:00 2001 From: Guillaume Ballet <3272758+gballet@users.noreply.github.com> Date: Wed, 22 Apr 2026 17:07:56 +0200 Subject: [PATCH] more rebase fixes --- trie/bintrie/store_commit.go | 2 +- trie/bintrie/trie.go | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/trie/bintrie/store_commit.go b/trie/bintrie/store_commit.go index 0cf52b1d64..2d1b3b05b5 100644 --- a/trie/bintrie/store_commit.go +++ b/trie/bintrie/store_commit.go @@ -255,7 +255,7 @@ func (s *nodeStore) collectNodes(ref nodeRef, path []byte, flushfn nodeFlushFn, } // Not at a group boundary - this shouldn't happen if we're called correctly from root // but handle it by continuing to traverse - return s.collectChildGroups(path, flushfn, groupDepth, groupDepth-(int(node.depth)%groupDepth)-1) + return s.collectChildGroups(node, path, flushfn, groupDepth, groupDepth-(int(node.depth)%groupDepth)-1) case kindStem: sn := s.getStem(ref.Index()) if !sn.dirty { diff --git a/trie/bintrie/trie.go b/trie/bintrie/trie.go index 5e19dd1e11..6b41b04cee 100644 --- a/trie/bintrie/trie.go +++ b/trie/bintrie/trie.go @@ -320,7 +320,7 @@ func (t *BinaryTrie) Commit(_ bool) (common.Hash, *trienode.NodeSet) { pathBuf := make([]byte, 0, 32) err := t.store.collectNodes(t.store.root, pathBuf, func(path []byte, hash common.Hash, serialized []byte) { nodeset.AddNode(path, trienode.NewNodeWithPrev(hash, serialized, t.tracer.Get(path))) - }) + }, t.groupDepth) if err != nil { panic(fmt.Errorf("CollectNodes failed: %v", err)) } @@ -347,7 +347,7 @@ func (t *BinaryTrie) Prove(key []byte, proofDb ethdb.KeyValueWriter) error { // Copy creates a deep copy of the trie. func (t *BinaryTrie) Copy() *BinaryTrie { return &BinaryTrie{ - root: t.root.Copy(), + store: t.store.Copy(), reader: t.reader, tracer: t.tracer.Copy(), groupDepth: t.groupDepth,