From 348c3bc47d8173ce24c5b92d697a5be289eea9a0 Mon Sep 17 00:00:00 2001 From: Martin Holst Swende Date: Tue, 13 Oct 2020 13:21:25 +0200 Subject: [PATCH] trie: fix flaw in stacktrie pool reuse (#21699) --- trie/stacktrie.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/trie/stacktrie.go b/trie/stacktrie.go index 33fa990077..ffccbbf4ac 100644 --- a/trie/stacktrie.go +++ b/trie/stacktrie.go @@ -113,7 +113,7 @@ func (st *StackTrie) Update(key, value []byte) { func (st *StackTrie) Reset() { st.db = nil st.key = st.key[:0] - st.val = st.val[:0] + st.val = nil for i := range st.children { st.children[i] = nil }