HomeFreeBSD

libnvmf: avoid resource leak

Description

libnvmf: avoid resource leak

In nvmf_host_fetch_discovery_log_page(), the log variable may have been
allocated on the heap during the first loop cycle, and should be
free()'d before exiting upon errors.

Reported by: Coverity
CID: 1545034
Sponsored by: The FreeBSD Foundation

Reviewed by: imp,jhb
Pull Request: https://github.com/freebsd/freebsd-src/pull/1239

Details

Provenance
khorben_defora.orgAuthored on May 16 2024, 2:34 PM
impCommitted on Tue, May 21, 11:41 PM
Parents
rGbd2d71b1c865: smb.4/smbfs.4: distinguishable descriptions, +SPDX
Branches
Unknown
Tags
Unknown