Skip to content

Commit

Permalink
[release-v1.8] vsp: Fix blocksUntilLive calc
Browse files Browse the repository at this point in the history
Backport of 45fef04
  • Loading branch information
jholdstock committed Aug 8, 2023
1 parent 07854e3 commit c4c6c42
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion internal/vsp/feepayment.go
Original file line number Diff line number Diff line change
Expand Up @@ -331,7 +331,7 @@ func (fp *feePayment) next() time.Duration {
var jitter time.Duration
switch {
case tipHeight < ticketLive: // immature, mined ticket
blocksUntilLive := ticketExpires - tipHeight
blocksUntilLive := ticketLive - tipHeight
jitter = params.TargetTimePerBlock * time.Duration(blocksUntilLive)
if jitter > immatureJitter {
jitter = immatureJitter
Expand Down

0 comments on commit c4c6c42

Please sign in to comment.