Skip to content

Commit

Permalink
fix: close file (radius-project#7608)
Browse files Browse the repository at this point in the history
# Description

_Please explain the changes you've made._

## Type of change

<!--

Please select **one** of the following options that describes your
change and delete the others. Clearly identifying the type of change you
are making will help us review your PR faster, and is used in authoring
release notes.

If you are making a bug fix or functionality change to Radius and do not
have an associated issue link please create one now.

-->

- This pull request fixes a bug in Radius and has an approved issue
(issue link required).
- This pull request adds or changes features of Radius and has an
approved issue (issue link required).
- This pull request is a minor refactor, code cleanup, test improvement,
or other maintenance task and doesn't change the functionality of Radius
(issue link optional).

<!--

Please update the following to link the associated issue. This is
required for some kinds of changes (see above).

-->

Fixes: #issue_number

Signed-off-by: guoguangwu <[email protected]>
  • Loading branch information
testwill authored May 21, 2024
1 parent 658dba7 commit 1a88d49
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions pkg/cli/tools/binary_tools.go
Original file line number Diff line number Diff line change
Expand Up @@ -166,6 +166,7 @@ func DownloadToFolder(filepath string) error {
if err != nil {
return fmt.Errorf("failed to open file %s: %v", filepath, err)
}
defer bicepBinary.Close()

// get the filemode so we can mark it as executable
file, err := bicepBinary.Stat()
Expand Down

0 comments on commit 1a88d49

Please sign in to comment.