diff options
author | OpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com> | 2022-03-10 09:02:06 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-03-10 09:02:06 -0500 |
commit | e10394da7e20daee66869d128339b1733a088999 (patch) | |
tree | 10a5d52ac81dec667b7de9d0e1d9f0138f6af8df /vendor/github.com/vbauerster/mpb/v7/proxyreader.go | |
parent | acfcecf2ae41528d1d7ecd43d37d8fd554f587bc (diff) | |
parent | a5353207c7c08c5ea81c8c358241b6a61173e93c (diff) | |
download | podman-e10394da7e20daee66869d128339b1733a088999.tar.gz podman-e10394da7e20daee66869d128339b1733a088999.tar.bz2 podman-e10394da7e20daee66869d128339b1733a088999.zip |
Merge pull request #13476 from containers/dependabot/go_modules/github.com/vbauerster/mpb/v7-7.4.1
Bump github.com/vbauerster/mpb/v7 from 7.3.2 to 7.4.1
Diffstat (limited to 'vendor/github.com/vbauerster/mpb/v7/proxyreader.go')
-rw-r--r-- | vendor/github.com/vbauerster/mpb/v7/proxyreader.go | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/vendor/github.com/vbauerster/mpb/v7/proxyreader.go b/vendor/github.com/vbauerster/mpb/v7/proxyreader.go index 25f195bb8..b0dd89d45 100644 --- a/vendor/github.com/vbauerster/mpb/v7/proxyreader.go +++ b/vendor/github.com/vbauerster/mpb/v7/proxyreader.go @@ -14,9 +14,6 @@ type proxyReader struct { func (x proxyReader) Read(p []byte) (int, error) { n, err := x.ReadCloser.Read(p) x.bar.IncrBy(n) - if err == io.EOF { - go x.bar.SetTotal(-1, true) - } return n, err } @@ -28,9 +25,6 @@ type proxyWriterTo struct { func (x proxyWriterTo) WriteTo(w io.Writer) (int64, error) { n, err := x.wt.WriteTo(w) x.bar.IncrInt64(n) - if err == io.EOF { - go x.bar.SetTotal(-1, true) - } return n, err } @@ -65,12 +59,12 @@ func (b *Bar) newProxyReader(r io.Reader) (rc io.ReadCloser) { pr := proxyReader{toReadCloser(r), b} if wt, ok := r.(io.WriterTo); ok { pw := proxyWriterTo{pr, wt} - if b.hasEwmaDecorators { + if b.hasEwma { rc = ewmaProxyWriterTo{ewmaProxyReader{pr}, pw} } else { rc = pw } - } else if b.hasEwmaDecorators { + } else if b.hasEwma { rc = ewmaProxyReader{pr} } else { rc = pr |