From 8551b0ebf752328ad1b9abcf02e588b7886ed523 Mon Sep 17 00:00:00 2001 From: derekwaynecarr Date: Mon, 25 Jul 2016 17:33:26 -0400 Subject: [PATCH] filesystem usage stats are wrong in v2 api --- info/v2/conversion.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/info/v2/conversion.go b/info/v2/conversion.go index b6664ecc..2e618120 100644 --- a/info/v2/conversion.go +++ b/info/v2/conversion.go @@ -24,7 +24,8 @@ import ( func machineFsStatsFromV1(fsStats []v1.FsStats) []MachineFsStats { var result []MachineFsStats - for _, stat := range fsStats { + for i := range fsStats { + stat := fsStats[i] readDuration := time.Millisecond * time.Duration(stat.ReadTime) writeDuration := time.Millisecond * time.Duration(stat.WriteTime) ioDuration := time.Millisecond * time.Duration(stat.IoTime)