Merge pull request #7942 from estesp/7747-stderr-stdout-bug
Fix gh#7747: filter bare newline output and log client pull to stdout
This commit is contained in:
commit
28e308c25e
|
@ -1967,7 +1967,7 @@ func (cli *DockerCli) pullImage(image string) error {
|
||||||
registryAuthHeader := []string{
|
registryAuthHeader := []string{
|
||||||
base64.URLEncoding.EncodeToString(buf),
|
base64.URLEncoding.EncodeToString(buf),
|
||||||
}
|
}
|
||||||
if err = cli.stream("POST", "/images/create?"+v.Encode(), nil, cli.err, map[string][]string{"X-Registry-Auth": registryAuthHeader}); err != nil {
|
if err = cli.stream("POST", "/images/create?"+v.Encode(), nil, cli.out, map[string][]string{"X-Registry-Auth": registryAuthHeader}); err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
return nil
|
return nil
|
||||||
|
|
|
@ -144,7 +144,9 @@ func DisplayJSONMessagesStream(in io.Reader, out io.Writer, terminalFd uintptr,
|
||||||
if !ok {
|
if !ok {
|
||||||
line = len(ids)
|
line = len(ids)
|
||||||
ids[jm.ID] = line
|
ids[jm.ID] = line
|
||||||
fmt.Fprintf(out, "\n")
|
if isTerminal {
|
||||||
|
fmt.Fprintf(out, "\n")
|
||||||
|
}
|
||||||
diff = 0
|
diff = 0
|
||||||
} else {
|
} else {
|
||||||
diff = len(ids) - line
|
diff = len(ids) - line
|
||||||
|
|
Loading…
Reference in New Issue