diff --git a/cli/command/image/build.go b/cli/command/image/build.go index 81cc8835f6..cbff43fde2 100644 --- a/cli/command/image/build.go +++ b/cli/command/image/build.go @@ -431,7 +431,7 @@ func runBuild(dockerCli command.Cli, options buildOptions) error { // should be just the image ID and we'll print that to stdout. if options.quiet { imageID = fmt.Sprintf("%s", buildBuff) - fmt.Fprintf(dockerCli.Out(), imageID) + _, _ = fmt.Fprint(dockerCli.Out(), imageID) } if options.imageIDFile != "" {