diff options
Diffstat (limited to 'nest')
-rw-r--r-- | nest/a-path_test.c | 8 | ||||
-rw-r--r-- | nest/a-set_test.c | 4 | ||||
-rw-r--r-- | nest/cli.c | 4 | ||||
-rw-r--r-- | nest/rt-table.c | 4 |
4 files changed, 10 insertions, 10 deletions
diff --git a/nest/a-path_test.c b/nest/a-path_test.c index fbf0f892..5e122396 100644 --- a/nest/a-path_test.c +++ b/nest/a-path_test.c @@ -32,7 +32,7 @@ t_as_path_match(void) struct adata *as_path = &empty_as_path; u32 first_prepended, last_prepended; first_prepended = last_prepended = 0; - struct linpool *lp = lp_new(&root_pool, 0); + struct linpool *lp = lp_new_default(&root_pool); struct f_path_mask mask[AS_PATH_LENGTH] = {}; int i; @@ -76,7 +76,7 @@ t_path_format(void) struct adata empty_as_path = {}; struct adata *as_path = &empty_as_path; - struct linpool *lp = lp_new(&root_pool, 0); + struct linpool *lp = lp_new_default(&root_pool); uint i; for (i = 4294967285; i <= 4294967294; i++) @@ -122,7 +122,7 @@ t_path_include(void) struct adata empty_as_path = {}; struct adata *as_path = &empty_as_path; - struct linpool *lp = lp_new(&root_pool, 0); + struct linpool *lp = lp_new_default(&root_pool); u32 as_nums[AS_PATH_LENGTH] = {}; int i; @@ -167,7 +167,7 @@ t_as_path_converting(void) struct adata empty_as_path = {}; struct adata *as_path = &empty_as_path; - struct linpool *lp = lp_new(&root_pool, 0); + struct linpool *lp = lp_new_default(&root_pool); #define AS_PATH_LENGTH_FOR_CONVERTING_TEST 10 int i; diff --git a/nest/a-set_test.c b/nest/a-set_test.c index f4588d65..a5081f9f 100644 --- a/nest/a-set_test.c +++ b/nest/a-set_test.c @@ -38,7 +38,7 @@ generate_set_sequence(enum set_type type) { struct adata empty_as_path = {}; set_sequence = set_sequence_same = set_sequence_higher = set_random = &empty_as_path; - lp = lp_new(&root_pool, 0); + lp = lp_new_default(&root_pool); int i; for (i = 0; i < SET_SIZE; i++) @@ -205,7 +205,7 @@ t_set_ec_format(void) struct adata empty_as_path = {}; set_sequence = set_sequence_same = set_sequence_higher = set_random = &empty_as_path; - lp = lp_new(&root_pool, 0); + lp = lp_new_default(&root_pool); u64 i = 0; set_sequence = ec_set_add(lp, set_sequence, i); @@ -313,8 +313,8 @@ cli_new(void *priv) c->event->hook = cli_event; c->event->data = c; c->cont = cli_hello; - c->parser_pool = lp_new(c->pool, 4080); - c->show_pool = lp_new(c->pool, 4080); + c->parser_pool = lp_new_default(c->pool); + c->show_pool = lp_new_default(c->pool); c->rx_buf = mb_alloc(c->pool, CLI_RX_BUF_SIZE); ev_schedule(c->event); return c; diff --git a/nest/rt-table.c b/nest/rt-table.c index bed9036e..85a951b8 100644 --- a/nest/rt-table.c +++ b/nest/rt-table.c @@ -1624,7 +1624,7 @@ rt_init(void) { rta_init(); rt_table_pool = rp_new(&root_pool, "Routing tables"); - rte_update_pool = lp_new(rt_table_pool, 4080); + rte_update_pool = lp_new_default(rt_table_pool); rte_slab = sl_new(rt_table_pool, sizeof(rte)); init_list(&routing_tables); } @@ -2304,7 +2304,7 @@ rt_init_hostcache(rtable *tab) hc_alloc_table(hc, HC_DEF_ORDER); hc->slab = sl_new(rt_table_pool, sizeof(struct hostentry)); - hc->lp = lp_new(rt_table_pool, 1008); + hc->lp = lp_new(rt_table_pool, LP_GOOD_SIZE(1024)); hc->trie = f_new_trie(hc->lp, sizeof(struct f_trie_node)); tab->hostcache = hc; |