Skip to content

Commit

Permalink
fix: miner: correctly count sector extensions
Browse files Browse the repository at this point in the history
  • Loading branch information
arajasek committed Mar 22, 2023
1 parent 8abe0ea commit b802658
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion cmd/lotus-miner/sectors.go
Original file line number Diff line number Diff line change
Expand Up @@ -1160,8 +1160,9 @@ var sectorsExtendCmd = &cli.Command{
}

sectorsInDecl := int(sectorsWithoutClaimsCount) + len(sectorsWithClaims)
scount += sectorsInDecl

if scount+sectorsInDecl > addrSectors || len(p.Extensions) >= declMax {
if scount > addrSectors || len(p.Extensions) >= declMax {
params = append(params, p)
p = miner.ExtendSectorExpiration2Params{}
scount = sectorsInDecl
Expand Down

0 comments on commit b802658

Please sign in to comment.