cbdata free handlers are underestimated

From: Henrik Nordstrom <hno@dont-contact.us>
Date: Sun, 25 Feb 2001 22:18:44 +0100

In "eventio" I have made quite extensive use of cbdata free handlers,
and it is a wonderful tool to use.

* I/O buffers are automatically deallocated when the last reference to
them dissapears. Behind the scenes IOBuf is a implemented as pooled
MemBuf which is freed but locked from start, requiring a free handler to
free the memory area the MemBuf refers to.

* Sockets are fully closed when the last reference to the filehandle is
gone after ncomm_close.

And many ofther quite helpful things.

Sure, initially there was perhaps a little more bugs than expected, but
almost all was "deference of null pointer". Not a single "reference of
freed pointer" yet, even if there is quite heavy use of pointers to keep
everything together. And the memory pool reports is quite helpful in
pinpointing memory leaks.

/Henrik
Received on Sun Feb 25 2001 - 14:33:38 MST

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:13:34 MST