diff --git a/bar.go b/bar.go index a7acbe6..d799d1d 100644 --- a/bar.go +++ b/bar.go @@ -210,6 +210,9 @@ for { select { case i := <-b.incrCh: + if i <= 0 { + break + } n := state.current + i if n > total { state.current = total