From 63331abbcadee3528f3e03f96cff1ca6a506cc9e Mon Sep 17 00:00:00 2001 From: Brian Goff Date: Tue, 14 Apr 2015 15:17:17 -0400 Subject: [PATCH] remove integration/utils setRaw funcs Signed-off-by: Brian Goff --- daemon/container.go | 9 --------- integration/utils.go | 21 --------------------- 2 files changed, 30 deletions(-) diff --git a/daemon/container.go b/daemon/container.go index e831f07a52..7cc874f67f 100644 --- a/daemon/container.go +++ b/daemon/container.go @@ -14,7 +14,6 @@ import ( "syscall" "time" - "github.com/docker/libcontainer" "github.com/docker/libcontainer/configs" "github.com/docker/libcontainer/devices" "github.com/docker/libcontainer/label" @@ -1020,14 +1019,6 @@ func (container *Container) Exposes(p nat.Port) bool { return exists } -func (container *Container) GetPtyMaster() (libcontainer.Console, error) { - ttyConsole, ok := container.command.ProcessConfig.Terminal.(execdriver.TtyTerminal) - if !ok { - return nil, ErrNoTTY - } - return ttyConsole.Master(), nil -} - func (container *Container) HostConfig() *runconfig.HostConfig { container.Lock() res := container.hostConfig diff --git a/integration/utils.go b/integration/utils.go index 20b88611c4..1d27cd6e42 100644 --- a/integration/utils.go +++ b/integration/utils.go @@ -9,7 +9,6 @@ import ( "time" "github.com/docker/docker/daemon" - "github.com/docker/docker/pkg/term" ) func closeWrap(args ...io.Closer) error { @@ -27,26 +26,6 @@ func closeWrap(args ...io.Closer) error { return nil } -func setRaw(t *testing.T, c *daemon.Container) *term.State { - pty, err := c.GetPtyMaster() - if err != nil { - t.Fatal(err) - } - state, err := term.MakeRaw(pty.Fd()) - if err != nil { - t.Fatal(err) - } - return state -} - -func unsetRaw(t *testing.T, c *daemon.Container, state *term.State) { - pty, err := c.GetPtyMaster() - if err != nil { - t.Fatal(err) - } - term.RestoreTerminal(pty.Fd(), state) -} - func waitContainerStart(t *testing.T, timeout time.Duration) *daemon.Container { var container *daemon.Container