freebsd-dev/sys/contrib/libnv
Mariusz Zaborski b5d787d93b libnv: fix memory leaks
nvpair_create_stringv: free the temporary string; this fix affects
nvlist_add_stringf() and nvlist_add_stringv().

nvpair_remove_nvlist_array (NV_TYPE_NVLIST_ARRAY case): free the chain
of nvpairs (as resetting it prevents nvlist_destroy() from freeing it).
Note: freeing the chain in nvlist_destroy() is not sufficient, because
it would still leak through nvlist_take_nvlist_array().  This affects
all nvlist_*_nvlist_array() use

Submitted by:	Mindaugas Rasiukevicius <rmind@netbsd.org>
Reported by:	clang/gcc ASAN
MFC after:	2 weeks
2019-02-10 23:28:55 +00:00
..
cnvlist.c libnv: Remove nvlist argument from cnvlist_{take,free}_* functions. 2018-06-18 21:26:58 +00:00
dnvlist.c Add SPDX tags for nv(9). 2018-01-27 12:58:21 +00:00
nv_impl.h libnv: fix memory leaks 2019-02-10 23:28:55 +00:00
nvlist_impl.h Add SPDX tags for nv(9). 2018-01-27 12:58:21 +00:00
nvlist.c libnv: fix memory leaks 2019-02-10 23:28:55 +00:00
nvpair_impl.h Add SPDX tags for nv(9). 2018-01-27 12:58:21 +00:00
nvpair.c libnv: fix memory leaks 2019-02-10 23:28:55 +00:00