diff --git a/tty.go b/tty.go index 015f00ccb..5ae0d76ae 100644 --- a/tty.go +++ b/tty.go @@ -159,11 +159,10 @@ func (t *tty) waitConsole() error { // ClosePostStart closes any fds that are provided to the container and dup2'd // so that we no longer have copy in our process. -func (t *tty) ClosePostStart() error { +func (t *tty) ClosePostStart() { for _, c := range t.postStart { _ = c.Close() } - return nil } // Close closes all open fds for the tty and/or restores the original diff --git a/utils_linux.go b/utils_linux.go index 43c8dd388..4f0c192ba 100644 --- a/utils_linux.go +++ b/utils_linux.go @@ -301,10 +301,7 @@ func (r *runner) run(config *specs.Process) (int, error) { r.terminate(process) return -1, err } - if err = tty.ClosePostStart(); err != nil { - r.terminate(process) - return -1, err - } + tty.ClosePostStart() if r.pidFile != "" { if err = createPidFile(r.pidFile, process); err != nil { r.terminate(process)