diff --git a/decor/eta.go b/decor/eta.go index c05c59d..308f203 100644 --- a/decor/eta.go +++ b/decor/eta.go @@ -84,6 +84,7 @@ } else { durPerItem := float64(d.zDur+dur) / float64(n) if math.IsInf(durPerItem, 0) || math.IsNaN(durPerItem) { + d.zDur += dur return } d.zDur = 0 diff --git a/decor/speed.go b/decor/speed.go index 9db4ea8..b867e5d 100644 --- a/decor/speed.go +++ b/decor/speed.go @@ -99,6 +99,7 @@ } else { durPerByte := float64(d.zDur+dur) / float64(n) if math.IsInf(durPerByte, 0) || math.IsNaN(durPerByte) { + d.zDur += dur return } d.zDur = 0