瀏覽代碼

Fix a scope issue preventing the close of slave stdin pty (#228)

Guillaume J. Charmes 12 年之前
父節點
當前提交
7efde5eb83
共有 1 個文件被更改,包括 2 次插入1 次删除
  1. 2 1
      container.go

+ 2 - 1
container.go

@@ -183,7 +183,8 @@ func (container *Container) startPty() error {
 	// stdin
 	var stdinSlave io.ReadCloser
 	if container.Config.OpenStdin {
-		stdinMaster, stdinSlave, err := pty.Open()
+		var stdinMaster io.WriteCloser
+		stdinMaster, stdinSlave, err = pty.Open()
 		if err != nil {
 			return err
 		}