From e78772af4dca453ed97ff25b03adbaec2054859a Mon Sep 17 00:00:00 2001 From: Stephen J Day Date: Fri, 29 Sep 2017 18:12:03 -0700 Subject: [PATCH] cli/command/container: ensure channel is allocated Signed-off-by: Stephen J Day --- cli/command/container/run.go | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/cli/command/container/run.go b/cli/command/container/run.go index c7aa60d6ab..a8aeae5350 100644 --- a/cli/command/container/run.go +++ b/cli/command/container/run.go @@ -290,8 +290,11 @@ func attachContainer( return nil, errAttach } + ch := make(chan error, 1) + *errCh = ch + go func() { - *errCh <- func() error { + ch <- func() error { streamer := hijackedIOStreamer{ streams: dockerCli, inputStream: in,