Skip to content

Commit

Permalink
Merge pull request #1034 from testwill/close_file
Browse files Browse the repository at this point in the history
fix: close resolv.conf
  • Loading branch information
s1061123 authored May 13, 2024
2 parents c053346 + 45a24d5 commit dc704d1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions plugins/ipam/host-local/dns.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ func parseResolvConf(filename string) (*types.DNS, error) {
if err != nil {
return nil, err
}
defer fp.Close()

dns := types.DNS{}
scanner := bufio.NewScanner(fp)
Expand Down

0 comments on commit dc704d1

Please sign in to comment.