diff --git a/winrm.go b/winrm.go index c42f41ca..10c24ec0 100644 --- a/winrm.go +++ b/winrm.go @@ -253,7 +253,7 @@ func (c *WinRM) Exec(cmd string, opts ...exec.Option) error { gotErrors = true o.LogErrorf("%s: %s", c, err.Error()) } - command.Stdout.Close() + command.Stderr.Close() }() command.Wait()