mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-17 18:30:45 +00:00
parent
56ef5f3956
commit
b08622248c
1 changed files with 6 additions and 2 deletions
|
|
@ -144,7 +144,9 @@ func (st *StackTrie) unmarshalBinary(r io.Reader) error {
|
||||||
Val []byte
|
Val []byte
|
||||||
Key []byte
|
Key []byte
|
||||||
}
|
}
|
||||||
gob.NewDecoder(r).Decode(&dec)
|
if err := gob.NewDecoder(r).Decode(&dec); err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
st.owner = dec.Owner
|
st.owner = dec.Owner
|
||||||
st.nodeType = dec.NodeType
|
st.nodeType = dec.NodeType
|
||||||
st.val = dec.Val
|
st.val = dec.Val
|
||||||
|
|
@ -158,7 +160,9 @@ func (st *StackTrie) unmarshalBinary(r io.Reader) error {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
var child StackTrie
|
var child StackTrie
|
||||||
child.unmarshalBinary(r)
|
if err := child.unmarshalBinary(r); err != nil {
|
||||||
|
return err
|
||||||
|
}
|
||||||
st.children[i] = &child
|
st.children[i] = &child
|
||||||
}
|
}
|
||||||
return nil
|
return nil
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue