Skip to content

Commit

Permalink
fix if
Browse files Browse the repository at this point in the history
  • Loading branch information
danwt committed May 9, 2024
1 parent 0fa595d commit 6b93370
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion block/produce.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ func (m *Manager) ProduceBlockLoop(ctx context.Context) {
case <-ticker.C:

// if empty blocks are configured to be enabled, and one is scheduled...
produceEmptyBlock := firstBlock || (0 < m.Conf.MaxIdleTime && nextEmptyBlock.Before(time.Now()))
produceEmptyBlock := firstBlock || 0 == m.Conf.MaxIdleTime || nextEmptyBlock.Before(time.Now())

Check warning

Code scanning / CodeQL

Calling the system time Warning

Calling the system time may be a possible source of non-determinism
firstBlock = false

block, commit, err := m.ProduceAndGossipBlock(ctx, produceEmptyBlock)
Expand Down

0 comments on commit 6b93370

Please sign in to comment.