Revert regression introduced in 81eac415ad03d93596a0d8da92bdccd9ecd4ee63, which caused 'docker run -i' to never close stdin

Upstream-commit: a6779bcae2df4805b8024c56f81ee3afac46ff93
Component: engine
This commit is contained in:
Solomon Hykes
2013-03-31 02:44:56 -07:00
parent cd7f78f436
commit fa190ee6b5

View File

@ -927,6 +927,7 @@ func (srv *Server) CmdRun(stdin io.ReadCloser, stdout io.Writer, args ...string)
if !config.Detach {
Go(func() error {
_, err := io.Copy(cmdStdin, stdin)
cmdStdin.Close()
return err
})
}