]> git.proxmox.com Git - libgit2.git/commitdiff
tests: fetchhead: fix memory leak
authorPatrick Steinhardt <ps@pks.im>
Thu, 27 Oct 2016 09:29:15 +0000 (11:29 +0200)
committerPatrick Steinhardt <ps@pks.im>
Thu, 27 Oct 2016 09:29:15 +0000 (11:29 +0200)
tests/online/fetchhead.c

index 9aaad253c06c119b05bc8af7d6243e8d17b8ad7d..c1ac06dbec8e2644593e1131dbde47fcba1143f2 100644 (file)
@@ -126,6 +126,8 @@ void test_online_fetchhead__explicit_dst_refspec_creates_branch(void)
 
        cl_git_pass(git_branch_lookup(&ref, g_repo, "explicit-refspec", GIT_BRANCH_ALL));
        cl_assert_equal_i(refs + 1, count_references());
+
+       git_reference_free(ref);
 }
 
 void test_online_fetchhead__empty_dst_refspec_creates_no_branch(void)