Merge sectorbuilder into sectorstorage
This commit is contained in:
parent
a975f018c5
commit
2dfa38f572
@ -3,8 +3,8 @@ package sealing
|
||||
import (
|
||||
"bytes"
|
||||
"context"
|
||||
"github.com/filecoin-project/lotus/storage/sectorstorage/zerocomm"
|
||||
|
||||
"github.com/filecoin-project/go-sectorbuilder"
|
||||
"github.com/ipfs/go-cid"
|
||||
cbg "github.com/whyrusleeping/cbor-gen"
|
||||
"golang.org/x/xerrors"
|
||||
@ -42,7 +42,7 @@ func checkPieces(ctx context.Context, si SectorInfo, api sealingApi) error {
|
||||
|
||||
for i, piece := range si.Pieces {
|
||||
if piece.DealID == nil {
|
||||
exp := sectorbuilder.ZeroPieceCommitment(piece.Size)
|
||||
exp := zerocomm.ZeroPieceCommitment(piece.Size)
|
||||
if piece.CommP != exp {
|
||||
return &ErrInvalidPiece{xerrors.Errorf("deal %d piece %d had non-zero CommP %+v", piece.DealID, i, piece.CommP)}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user