Date: Mon, 4 Jan 2016 03:34:22 +0000 (UTC) From: Garrett Cooper <ngie@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r293135 - head/lib/libnv/tests Message-ID: <201601040334.u043YM2p010674@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: ngie Date: Mon Jan 4 03:34:22 2016 New Revision: 293135 URL: https://svnweb.freebsd.org/changeset/base/293135 Log: Remove free'ing of an uninitialized variable Just remove it completely from the test as it's initialized but unused apart from the free(3) call Differential Revision: https://reviews.freebsd.org/D4769 (part of larger diff) MFC after: 5 days Reported by: cppcheck Reviewed by: oshogbo Sponsored by: EMC / Isilon Storage Division Modified: head/lib/libnv/tests/nv_array_tests.cc Modified: head/lib/libnv/tests/nv_array_tests.cc ============================================================================== --- head/lib/libnv/tests/nv_array_tests.cc Mon Jan 4 03:26:36 2016 (r293134) +++ head/lib/libnv/tests/nv_array_tests.cc Mon Jan 4 03:34:22 2016 (r293135) @@ -1101,7 +1101,6 @@ ATF_TEST_CASE_BODY(nvlist_nvlist_array__ { nvlist_t *testnvl[8], *unpacked; const nvlist_t * const *const_result; - nvlist_t **result; nvlist_t *nvl; size_t num_items, packed_size; unsigned int i; @@ -1159,7 +1158,6 @@ ATF_TEST_CASE_BODY(nvlist_nvlist_array__ for (i = 0; i < nitems(testnvl); i++) nvlist_destroy(testnvl[i]); - free(result); nvlist_destroy(nvl); nvlist_destroy(unpacked); free(packed);
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201601040334.u043YM2p010674>