summaryrefslogtreecommitdiff
path: root/src/or/test.c
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2007-04-11 00:30:34 +0000
committerNick Mathewson <nickm@torproject.org>2007-04-11 00:30:34 +0000
commit51e4b8d7068a3489fb5cb45a8ebcc20036fd0d35 (patch)
treecad4e30bb647186680938182bcd0592917acf4ea /src/or/test.c
parent28de06b8e654800bb1221467d6c8cbbf8d19987d (diff)
downloadtor-51e4b8d7068a3489fb5cb45a8ebcc20036fd0d35.tar.gz
tor-51e4b8d7068a3489fb5cb45a8ebcc20036fd0d35.zip
r12338@catbus: nickm | 2007-04-10 20:29:05 -0400
Document memory pool implementation, and tweak it even mor. See? Programming is fun. svn:r9940
Diffstat (limited to 'src/or/test.c')
-rw-r--r--src/or/test.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/or/test.c b/src/or/test.c
index 7294e413a7..9b427cfa76 100644
--- a/src/or/test.c
+++ b/src/or/test.c
@@ -2142,13 +2142,15 @@ test_mempool(void)
//mp_pool_assert_ok(pool);
}
if (crypto_rand_int(777)==0)
- mp_pool_clean(pool);
+ mp_pool_clean(pool, 2);
if (i % 777)
mp_pool_assert_ok(pool);
}
SMARTLIST_FOREACH(allocated, void *, m, mp_pool_release(m));
mp_pool_assert_ok(pool);
+ mp_pool_clean(pool, 0);
+ mp_pool_assert_ok(pool);
mp_pool_destroy(pool);
smartlist_free(allocated);
}