summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorMaria Matejka <mq@ucw.cz>2022-03-02 10:59:52 +0100
committerMaria Matejka <mq@ucw.cz>2022-03-02 12:13:49 +0100
commitd814a8cb9381e8cb22c3f37d3c970ca7972656a6 (patch)
treec75c0aaded6206d55f0cf181b22321f8150ecfde /lib
parent48bf1322aa141ca6259b26b37551402758cff0cc (diff)
Replaced custom linpools in tests for the common tmp_linpool
Diffstat (limited to 'lib')
-rw-r--r--lib/flowspec_test.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/lib/flowspec_test.c b/lib/flowspec_test.c
index ed4afe51..115084a3 100644
--- a/lib/flowspec_test.c
+++ b/lib/flowspec_test.c
@@ -449,7 +449,6 @@ t_builder4(void)
resource_init();
struct flow_builder *fb = flow_builder_init(&root_pool);
- linpool *lp = lp_new_default(&root_pool);
/* Expectation */
@@ -492,7 +491,7 @@ t_builder4(void)
flow_builder_set_type(fb, FLOW_TYPE_TCP_FLAGS);
flow_builder_add_op_val(fb, 0, 0x55);
- net_addr_flow4 *res = flow_builder4_finalize(fb, lp);
+ net_addr_flow4 *res = flow_builder4_finalize(fb, tmp_linpool);
bt_assert(memcmp(res, expect, expect->length) == 0);
@@ -530,7 +529,6 @@ t_builder6(void)
net_addr_ip6 ip;
resource_init();
- linpool *lp = lp_new_default(&root_pool);
struct flow_builder *fb = flow_builder_init(&root_pool);
fb->ipv6 = 1;
@@ -574,7 +572,7 @@ t_builder6(void)
flow_builder_set_type(fb, FLOW_TYPE_LABEL);
flow_builder_add_op_val(fb, 0, 0x55);
- net_addr_flow6 *res = flow_builder6_finalize(fb, lp);
+ net_addr_flow6 *res = flow_builder6_finalize(fb, tmp_linpool);
bt_assert(memcmp(res, expect, expect->length) == 0);
/* Reverse order */
@@ -601,7 +599,7 @@ t_builder6(void)
flow_builder_set_type(fb, FLOW_TYPE_DST_PREFIX);
flow_builder6_add_pfx(fb, &ip, 61);
- res = flow_builder6_finalize(fb, lp);
+ res = flow_builder6_finalize(fb, tmp_linpool);
bt_assert(memcmp(res, expect, expect->length) == 0);
return 1;