diff --git a/cio/io_windows.go b/cio/io_windows.go index fa9532a3b..a751f7d7a 100644 --- a/cio/io_windows.go +++ b/cio/io_windows.go @@ -20,7 +20,6 @@ import ( "fmt" "io" "net" - "sync" winio "github.com/Microsoft/go-winio" "github.com/containerd/containerd/log" @@ -41,7 +40,6 @@ func NewFIFOSetInDir(_, id string, terminal bool) (*FIFOSet, error) { func copyIO(fifos *FIFOSet, ioset *Streams) (*cio, error) { var ( - wg sync.WaitGroup set []io.Closer ) @@ -85,9 +83,7 @@ func copyIO(fifos *FIFOSet, ioset *Streams) (*cio, error) { }(l) set = append(set, l) - wg.Add(1) go func() { - defer wg.Done() c, err := l.Accept() if err != nil { log.L.WithError(err).Errorf("failed to accept stdout connection on %s", fifos.Stdout) @@ -115,9 +111,7 @@ func copyIO(fifos *FIFOSet, ioset *Streams) (*cio, error) { }(l) set = append(set, l) - wg.Add(1) go func() { - defer wg.Done() c, err := l.Accept() if err != nil { log.L.WithError(err).Errorf("failed to accept stderr connection on %s", fifos.Stderr)