summaryrefslogtreecommitdiff
path: root/tests/test-bitmap.c
diff options
context:
space:
mode:
authorThomas Graf <tgraf@noironetworks.com>2014-09-01 18:10:26 +0200
committerBen Pfaff <blp@nicira.com>2014-09-02 08:37:50 -0700
commitc44a2a6df4ebde5ec9752d08ff82fec7f0c5c90c (patch)
treedf46bce4e9b92160fde43a2964aea1dbb8867002 /tests/test-bitmap.c
parentb4bb68c2bcf45687e6b63ba1b7cb21dcbf89ea0a (diff)
downloadopenvswitch-c44a2a6df4ebde5ec9752d08ff82fec7f0c5c90c.tar.gz
test-bitmap: Fix multiple minor memory leaks
Signed-off-by: Thomas Graf <tgraf@noironetworks.com> Signed-off-by: Ben Pfaff <blp@nicira.com>
Diffstat (limited to 'tests/test-bitmap.c')
-rw-r--r--tests/test-bitmap.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/test-bitmap.c b/tests/test-bitmap.c
index b1274e3ed..3644419d1 100644
--- a/tests/test-bitmap.c
+++ b/tests/test-bitmap.c
@@ -56,6 +56,9 @@ test_bitmap_equal(void)
assert(!bitmap_equal(a, b, 11 * BITMAP_ULONG_BITS - 1));
assert(!bitmap_equal(a, b,
11 * BITMAP_ULONG_BITS - (BITMAP_ULONG_BITS - 1)));
+
+ free(b);
+ free(a);
}
/* Tests bitmap_scan. */
@@ -107,6 +110,8 @@ test_bitmap_scan(void)
assert(bitmap_scan(a, false, 0, MAX_BITS - 1) == BITMAP_ULONG_BITS - 1);
bitmap_set0(a, 0);
assert(bitmap_scan(a, false, 0, MAX_BITS - 1) == 0);
+
+ free(a);
}
static void