From 22c411517a4a203690edb52fa42f8d5b43252882 Mon Sep 17 00:00:00 2001 From: Sebastiaan van Stijn Date: Fri, 13 Jan 2017 10:25:03 +0100 Subject: [PATCH] revert "virtualSize" name change Commit b717de5153db503fae61c11e30f04f400f66a6fd changed the name of the "size" argument to "virtualSize", as the "VirtualSize" field was re-used for calculating the size of all layers _not_ used by other images. be20dc15af0cb281bd6d11586cfcc96bd50d12ca reverted the change in calculation, but did not change the argument name back to "size". This changes the name back to its original name, because since the introduction of the content-addressable store in docker 1.10, there no longer is a "virtual" size, so "size" is a better name for this argument. Signed-off-by: Sebastiaan van Stijn --- daemon/images.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/daemon/images.go b/daemon/images.go index 01dbced164..642802abce 100644 --- a/daemon/images.go +++ b/daemon/images.go @@ -315,13 +315,13 @@ func (daemon *Daemon) SquashImage(id, parent string) (string, error) { return string(newImgID), nil } -func newImage(image *image.Image, virtualSize int64) *types.ImageSummary { +func newImage(image *image.Image, size int64) *types.ImageSummary { newImage := new(types.ImageSummary) newImage.ParentID = image.Parent.String() newImage.ID = image.ID().String() newImage.Created = image.Created.Unix() - newImage.Size = virtualSize - newImage.VirtualSize = virtualSize + newImage.Size = size + newImage.VirtualSize = size newImage.SharedSize = -1 newImage.Containers = -1 if image.Config != nil {