From aa5757a84a1038ee37620ab79c1214bba315b667 Mon Sep 17 00:00:00 2001 From: b00ris Date: Wed, 8 Jan 2020 20:02:24 +0300 Subject: [PATCH] fix test (#306) --- core/state/database_test.go | 2 +- core/types/accounts/account.go | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/core/state/database_test.go b/core/state/database_test.go index 143db9e35..7658bc6e4 100644 --- a/core/state/database_test.go +++ b/core/state/database_test.go @@ -1150,7 +1150,7 @@ func TestWrongIncarnation2(t *testing.T) { t.Fatal(err) } if acc.Incarnation != state.NonContractIncarnation { - t.Fatal("wrong incarnation") + t.Fatal("wrong incarnation", acc.Incarnation) } } diff --git a/core/types/accounts/account.go b/core/types/accounts/account.go index 837799141..17c212639 100644 --- a/core/types/accounts/account.go +++ b/core/types/accounts/account.go @@ -534,6 +534,7 @@ func (a *Account) DecodeForHashing(enc []byte) error { func (a *Account) DecodeForStorage(enc []byte) error { a.Initialised = true a.Nonce = 0 + a.Incarnation = 0 a.Balance.SetInt64(0) a.Root = emptyRoot a.CodeHash = emptyCodeHash