aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/libarchive/tar/test/test_option_gid_gname.c
diff options
context:
space:
mode:
Diffstat (limited to 'contrib/libarchive/tar/test/test_option_gid_gname.c')
-rw-r--r--contrib/libarchive/tar/test/test_option_gid_gname.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/contrib/libarchive/tar/test/test_option_gid_gname.c b/contrib/libarchive/tar/test/test_option_gid_gname.c
index e45da5b91463..4e5f51c8f486 100644
--- a/contrib/libarchive/tar/test/test_option_gid_gname.c
+++ b/contrib/libarchive/tar/test/test_option_gid_gname.c
@@ -53,6 +53,7 @@ DEFINE_TEST(test_option_gid_gname)
/* Should force gid and gname fields in ustar header. */
assertEqualMem(data + 116, "000021 \0", 8);
assertEqualMem(data + 297, "foofoofoo\0", 10);
+ free(data);
/* Again with just --gname */
failure("Error invoking %s c", testprog);
@@ -65,6 +66,8 @@ DEFINE_TEST(test_option_gid_gname)
/* Gid should be unchanged from original reference. */
assertEqualMem(data + 116, reference + 116, 8);
assertEqualMem(data + 297, "foofoofoo\0", 10);
+ free(data);
+ free(reference);
/* Again with --gid and force gname to empty. */
failure("Error invoking %s c", testprog);
@@ -77,6 +80,7 @@ DEFINE_TEST(test_option_gid_gname)
assertEqualMem(data + 116, "000021 \0", 8);
/* Gname field in ustar header should be empty. */
assertEqualMem(data + 297, "\0", 1);
+ free(data);
/* TODO: It would be nice to verify that --gid= by itself
* will look up the associated gname and use that, but