From 03924bc439443c33947a087a0cb8a0ed248227aa Mon Sep 17 00:00:00 2001 From: Daniel Hiltgen Date: Mon, 27 Aug 2018 14:43:40 -0700 Subject: [PATCH] Fix progress reporting for containerd pulls During refactoring of the implementation PR progress reporting was broken. This gets the progress reporting back in action. Signed-off-by: Daniel Hiltgen (cherry picked from commit 7f4c842e8a99e930660f51cb4fa2eb4a7e786e09) Signed-off-by: Daniel Hiltgen --- internal/containerizedengine/progress.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/internal/containerizedengine/progress.go b/internal/containerizedengine/progress.go index 449ffc61d5..9ff2be52ab 100644 --- a/internal/containerizedengine/progress.go +++ b/internal/containerizedengine/progress.go @@ -64,7 +64,7 @@ outer: } } - err := updateNonActive(ctx, ongoing, cs, statuses, keys, activeSeen, &done, start) + err := updateNonActive(ctx, ongoing, cs, statuses, &keys, activeSeen, &done, start) if err != nil { continue outer } @@ -92,11 +92,11 @@ outer: } } -func updateNonActive(ctx context.Context, ongoing *jobs, cs content.Store, statuses map[string]statusInfo, keys []string, activeSeen map[string]struct{}, done *bool, start time.Time) error { +func updateNonActive(ctx context.Context, ongoing *jobs, cs content.Store, statuses map[string]statusInfo, keys *[]string, activeSeen map[string]struct{}, done *bool, start time.Time) error { for _, j := range ongoing.jobs() { key := remotes.MakeRefKey(ctx, j) - keys = append(keys, key) + *keys = append(*keys, key) if _, ok := activeSeen[key]; ok { continue }