__uc_malloc hooks

Dave Dodge dododge at dododge.net
Mon Sep 17 08:08:37 PDT 2007


On Mon, Sep 17, 2007 at 11:00:23AM +0100, Denys Vlasenko wrote:
> On Monday 17 September 2007 05:03, Rob Landley wrote:
> > That said, testing for NULL is seldom useful because attempts to use the 
> > result give you a nice null pointer dereference and a segfault, cleanly 
> > ending the program anyway.
> 
> For libc, this is not acceptable.

Yeah, this sort of abort-on-oom behavior is exactly what keeps me from
using glibc's fancy features.  For example the obstack API aborts on
OOM by default.  It does give the ability to set an error handler, but
that's still really not good enough because the programs where I
actually _care_ about these errors tend to be heavily threaded.

                                                  -Dave Dodge


More information about the uClibc mailing list