File tree Expand file tree Collapse file tree 2 files changed +4
-3
lines changed
Expand file tree Collapse file tree 2 files changed +4
-3
lines changed Original file line number Diff line number Diff line change @@ -31,7 +31,7 @@ var Conf = struct {
3131}{
3232 PathRule : "/rule.ls" ,
3333 PathCIDR : "/rule.cidr" ,
34- Version : "v1.24.0 " ,
34+ Version : "v1.24.1 " ,
3535}
3636
3737const helpMsg = `Usage: daze <command> [<args>]
Original file line number Diff line number Diff line change @@ -21,7 +21,7 @@ type Limits struct {
2121
2222// Wait ensures there are enough resources (n) available, blocking if necessary.
2323func (l * Limits ) Wait (n uint64 ) {
24- doa .Doa (n > 0 && n < math .MaxUint64 / 2 )
24+ doa .Doa (n < math .MaxUint64 / 2 )
2525 l .mu .Lock ()
2626 defer l .mu .Unlock ()
2727 l .loop = uint64 (time .Since (l .last ) / l .step )
@@ -43,7 +43,8 @@ func (l *Limits) Wait(n uint64) {
4343
4444// NewLimits creates a new rate limiter with rate r over period p.
4545func NewLimits (r uint64 , p time.Duration ) * Limits {
46- doa .Doa (r > 0 && r < math .MaxUint64 / 2 )
46+ doa .Doa (r > 0 )
47+ doa .Doa (r < math .MaxUint64 / 2 )
4748 doa .Doa (p > 0 )
4849 g := func (a , b uint64 ) uint64 {
4950 t := uint64 (0 )
You can’t perform that action at this time.
0 commit comments