diff options
author | Giuseppe Scrivano <gscrivan@redhat.com> | 2022-01-14 13:13:04 +0100 |
---|---|---|
committer | Giuseppe Scrivano <gscrivan@redhat.com> | 2022-01-24 16:05:46 +0100 |
commit | 75e6994d4edc712a281aaa46574ed90ecd19ba49 (patch) | |
tree | f856b1d7bc0d3589629efa362a27cd7ad1325d8e /libpod | |
parent | f6e36a64975fdd9c39507f4447a469de1e850598 (diff) | |
download | podman-75e6994d4edc712a281aaa46574ed90ecd19ba49.tar.gz podman-75e6994d4edc712a281aaa46574ed90ecd19ba49.tar.bz2 podman-75e6994d4edc712a281aaa46574ed90ecd19ba49.zip |
libpod: fix leaking fd
the config.json file for the OCI runtime is never closed, this is a
problem when running on NFS, since it leaves around stale files that
cannot be unlinked.
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
Diffstat (limited to 'libpod')
-rw-r--r-- | libpod/oci_conmon_exec_linux.go | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/libpod/oci_conmon_exec_linux.go b/libpod/oci_conmon_exec_linux.go index 29c600109..04deaac83 100644 --- a/libpod/oci_conmon_exec_linux.go +++ b/libpod/oci_conmon_exec_linux.go @@ -389,6 +389,7 @@ func (r *ConmonOCIRuntime) startExec(c *Container, sessionID string, options *Ex if err != nil { return nil, nil, err } + defer processFile.Close() args := r.sharedConmonArgs(c, sessionID, c.execBundlePath(sessionID), c.execPidPath(sessionID), c.execLogPath(sessionID), c.execExitFileDir(sessionID), ociLog, define.NoLogging, "") |