These are known and really hard to fix bugs.
These would need design changes or whole code audit.
xhash pool leak by misuse
There are many uses of xhash like this:
Persistant per process hash is created and then used like:
xhash_put(xhash_instance, pstrdup(xhash_pool(xhash_instance), key_string), (void *) data);
So, the memory for the key string is taken from the hash pool. This way after removing the item from xhash with xhash_zap() the key string is left in the hash memory pool leaked permanently, because the lifetime of the hash is persistant.
Solution: track the source of every xhash entry and allocate its key string in its memory pool - this way the keys that was used to track the object will disappear with the object itself.