From 2764d18751f21ec324255f42e5083469afb0e600 Mon Sep 17 00:00:00 2001 From: Paul Holzinger Date: Thu, 30 Jul 2020 21:16:59 +0200 Subject: fix swapped mem_usage/percent fields Correct the wrong field assignment in `podman stats --format=json`. Signed-off-by: Paul Holzinger --- cmd/podman/containers/stats.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/podman/containers/stats.go b/cmd/podman/containers/stats.go index 2b4c46647..ddb5f32ef 100644 --- a/cmd/podman/containers/stats.go +++ b/cmd/podman/containers/stats.go @@ -230,8 +230,8 @@ func outputJSON(stats []*containerStats) error { Id: j.ID(), Name: j.Name, CpuPercent: j.CPUPerc(), - MemUsage: j.MemPerc(), - MemPerc: j.MemUsage(), + MemUsage: j.MemUsage(), + MemPerc: j.MemPerc(), NetIO: j.NetIO(), BlockIO: j.BlockIO(), Pids: j.PIDS(), -- cgit v1.2.3-54-g00ecf