Fix some memory leaks in the slab allocator (funny, isn't it?).
authorMichael Poole <mdpoole@troilus.org>
Fri, 14 Dec 2007 03:56:03 +0000 (22:56 -0500)
committerMichael Poole <mdpoole@troilus.org>
Fri, 14 Dec 2007 03:56:03 +0000 (22:56 -0500)
commit06c6659adc40c92eba5473f2dd30db51422e3ab4
tree3396bf18cb92de6bcb6f5940e92ea034eda6e396
parenta96bcd75a7530b0f9a25209b585e3ee18dc49937
Fix some memory leaks in the slab allocator (funny, isn't it?).

alloc-slab.c (SLAB_DEBUG): Allow environment to override definition.
  (SLAB_RESERVE): Likewise.
  (MAX_SLAB_FREE): New preprocessor macro, used to cap free_slab_count.
  (slab_unalloc): Reindent SLAB_RESERVE logic.  Unconditionally link the
    free slab to the list of free slabs.  Add code to check MAX_SLAB_FREE.
src/alloc-slab.c