Skip to content

Commit

Permalink
fix(command): ensure session is properly closed
Browse files Browse the repository at this point in the history
  • Loading branch information
windvalley committed Dec 17, 2024
1 parent 92f92f3 commit d838b87
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pkg/batchssh/batchssh.go
Original file line number Diff line number Diff line change
Expand Up @@ -177,6 +177,7 @@ func (c *Client) ExecuteCmd(host *Host, command, lang, runAs string, sudo bool)
if err != nil {
return "", err
}
defer session.Close()

exportLang := ""
if lang != "" {
Expand Down

0 comments on commit d838b87

Please sign in to comment.