diff options
Diffstat (limited to 'lib/mempool.c')
-rw-r--r-- | lib/mempool.c | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/lib/mempool.c b/lib/mempool.c index d10f8f1c..5200f5e7 100644 --- a/lib/mempool.c +++ b/lib/mempool.c @@ -42,7 +42,7 @@ struct linpool { }; static void lp_free(resource *); -static void lp_dump(resource *); +static void lp_dump(resource *, unsigned); static resource *lp_lookup(resource *, unsigned long); static struct resmem lp_memsize(resource *r); @@ -262,11 +262,12 @@ lp_free(resource *r) } static void -lp_dump(resource *r) +lp_dump(resource *r, unsigned indent) { linpool *m = (linpool *) r; struct lp_chunk *c; int cnt, cntl; + char x[32]; for(cnt=0, c=m->first; c; c=c->next, cnt++) ; @@ -277,6 +278,14 @@ lp_dump(resource *r) cntl, m->total, m->total_large); + + bsprintf(x, "%%%dschunk %%p\n", indent + 2); + for (c=m->first; c; c=c->next) + debug(x, "", c); + + bsprintf(x, "%%%dslarge %%p\n", indent + 2); + for (c=m->first_large; c; c=c->next) + debug(x, "", c); } static struct resmem |