Update post-processor/vsphere/post-processor.go

Co-authored-by: Adrien Delorme <azr@users.noreply.github.com>
This commit is contained in:
Megan Marsh 2020-07-27 08:52:29 -07:00 committed by GitHub
parent c34e89aec7
commit 69b0e66b5d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 1 deletions

View File

@ -222,7 +222,10 @@ func (p *PostProcessor) ValidateOvfTool(args []string, ofvtool string) error {
// Need to manually close stdin or else the ofvtool call will hang
// forever in a situation where the user has provided an invalid
// password or username
stdin, _ := cmd.StdinPipe()
stdin, err := cmd.StdinPipe()
if err != nil {
err
}
defer stdin.Close()
if err := cmd.Run(); err != nil {