Function mpool_ref_count
Defined in File mpool.h
Function Documentation
-
size_t mpool_ref_count(struct mpool *the_pool, const void *ptr)
Get the reference count of an allocated chunk in a mpool.
Note
The returned value cannot be relied upon in concurrent contexts without additional synchronization.
- Parameters:
the_pool – The mpool handle.
ptr – The chunk to query.
- Returns:
The reference count, or 0 on error.