mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-12-06 19:41:15 +01:00
Add --disable-mempools configure option
This commit is contained in:
@@ -16,7 +16,10 @@ test_cq_manip(void *arg)
|
||||
cell_t cell;
|
||||
(void) arg;
|
||||
|
||||
#ifdef ENABLE_MEMPOOLS
|
||||
init_cell_pool();
|
||||
#endif /* ENABLE_MEMPOOLS */
|
||||
|
||||
cell_queue_init(&cq);
|
||||
tt_int_op(cq.n, ==, 0);
|
||||
|
||||
@@ -96,7 +99,10 @@ test_cq_manip(void *arg)
|
||||
packed_cell_free(pc_tmp);
|
||||
|
||||
cell_queue_clear(&cq);
|
||||
|
||||
#ifdef ENABLE_MEMPOOLS
|
||||
free_cell_pool();
|
||||
#endif /* ENABLE_MEMPOOLS */
|
||||
}
|
||||
|
||||
static void
|
||||
@@ -108,7 +114,9 @@ test_circuit_n_cells(void *arg)
|
||||
|
||||
(void)arg;
|
||||
|
||||
#ifdef ENABLE_MEMPOOLS
|
||||
init_cell_pool();
|
||||
#endif /* ENABLE_MEMPOOLS */
|
||||
|
||||
pc1 = packed_cell_new();
|
||||
pc2 = packed_cell_new();
|
||||
@@ -137,7 +145,9 @@ test_circuit_n_cells(void *arg)
|
||||
circuit_free(TO_CIRCUIT(or_c));
|
||||
circuit_free(TO_CIRCUIT(origin_c));
|
||||
|
||||
#ifdef ENABLE_MEMPOOLS
|
||||
free_cell_pool();
|
||||
#endif /* ENABLE_MEMPOOLS */
|
||||
}
|
||||
|
||||
struct testcase_t cell_queue_tests[] = {
|
||||
|
||||
Reference in New Issue
Block a user