Skip to content

Commit

Permalink
Merge pull request #4347 from filecoin-project/fix/sync/message-valid…
Browse files Browse the repository at this point in the history
…ation-state-height

fix(sync state): set state height to actual tipset height
  • Loading branch information
magik6k committed Oct 13, 2020
2 parents 5fd0bf1 + 9b4cac9 commit 1a70dbe
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion chain/sync.go
Original file line number Diff line number Diff line change
Expand Up @@ -1478,7 +1478,7 @@ func (syncer *Syncer) syncFork(ctx context.Context, incoming *types.TipSet, know

func (syncer *Syncer) syncMessagesAndCheckState(ctx context.Context, headers []*types.TipSet) error {
ss := extractSyncState(ctx)
ss.SetHeight(0)
ss.SetHeight(headers[len(headers)-1].Height())

return syncer.iterFullTipsets(ctx, headers, func(ctx context.Context, fts *store.FullTipSet) error {
log.Debugw("validating tipset", "height", fts.TipSet().Height(), "size", len(fts.TipSet().Cids()))
Expand Down

0 comments on commit 1a70dbe

Please sign in to comment.