Skip to content

Commit a7196e4

Browse files
committed
govc: host.info: use writer instead of os.stdout
Closes: #2995
1 parent 17e669d commit a7196e4

File tree

1 file changed

+1
-2
lines changed

1 file changed

+1
-2
lines changed

govc/host/info.go

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@ import (
2121
"flag"
2222
"fmt"
2323
"io"
24-
"os"
2524
"text/tabwriter"
2625

2726
"github.com/vmware/govmomi/govc/cli"
@@ -132,7 +131,7 @@ func (r *infoResult) Write(w io.Writer) error {
132131
objects[o.Reference()] = o
133132
}
134133

135-
tw := tabwriter.NewWriter(os.Stdout, 2, 0, 2, ' ', 0)
134+
tw := tabwriter.NewWriter(w, 2, 0, 2, ' ', 0)
136135

137136
for _, o := range r.objects {
138137
host := objects[o.Reference()]

0 commit comments

Comments
 (0)