mirror of https://github.com/containers/podman.git
Merge pull request #22404 from testwill/close_file
fix: close resource file
This commit is contained in:
commit
4f31335fa4
|
@ -342,6 +342,7 @@ func generateResourceFile(res *spec.LinuxResources) (string, []string, error) {
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return "", nil, err
|
return "", nil, err
|
||||||
}
|
}
|
||||||
|
defer f.Close()
|
||||||
|
|
||||||
j, err := json.Marshal(res)
|
j, err := json.Marshal(res)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
Loading…
Reference in New Issue