diff --git a/progress.go b/progress.go index 55af3c9..8a8f1bd 100644 --- a/progress.go +++ b/progress.go @@ -254,7 +254,7 @@ func (s *pState) flush(cw *cwriter.Writer, height int) error { var popCount int - rows := make([]io.Reader, 0, s.bHeap.Len()) + rows := make([]io.Reader, 0, height) pool := make([]*Bar, 0, s.bHeap.Len()) for s.bHeap.Len() > 0 { var frameRowsUsed int