From b6ad9d08f9c4cc540bbcf0a8ee0c51822691d3c0 Mon Sep 17 00:00:00 2001 From: Solomon Hykes Date: Thu, 21 Mar 2013 18:59:12 -0700 Subject: [PATCH] Fixed output quirks in 'docker images' Upstream-commit: 4af8b711c0b86b38a851ec19b2a00e1317496924 Component: engine --- components/engine/commands.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/components/engine/commands.go b/components/engine/commands.go index 78d24ad0a0..4b23204854 100644 --- a/components/engine/commands.go +++ b/components/engine/commands.go @@ -454,7 +454,7 @@ func (srv *Server) CmdImages(stdin io.ReadCloser, stdout io.Writer, args ...stri } } // Display images which aren't part of a - if nameFilter != "" { + if nameFilter == "" { for id, image := range allImages { if !*quiet { for idx, field := range []string{ @@ -470,6 +470,7 @@ func (srv *Server) CmdImages(stdin io.ReadCloser, stdout io.Writer, args ...stri w.Write([]byte("\t" + field)) } } + w.Write([]byte{'\n'}) } else { stdout.Write([]byte(image.Id + "\n")) }