From fed9ebe39df6914c603ea8a7ee9a270bf441d107 Mon Sep 17 00:00:00 2001 From: Nitish Tiwari Date: Fri, 26 May 2017 10:17:50 -0700 Subject: [PATCH] - Call the progress bar Finish method once all files are updated (#2165) - Fixes https://github.com/minio/mc/issues/2161 --- cmd/mirror-main.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cmd/mirror-main.go b/cmd/mirror-main.go index ad7516da..247017d1 100644 --- a/cmd/mirror-main.go +++ b/cmd/mirror-main.go @@ -229,7 +229,6 @@ func (mj *mirrorJob) startStatus() { go func() { // now we want to start the progress bar mj.status.Start() - defer mj.status.Finish() defer mj.wgStatus.Done() for sURLs := range mj.statusCh { @@ -262,6 +261,7 @@ func (mj *mirrorJob) startStatus() { func (mj *mirrorJob) stopStatus() { close(mj.statusCh) mj.wgStatus.Wait() + mj.status.Finish() } // this goroutine will watch for notifications, and add modified objects to the queue