Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 22 Jul 2001 23:47:24 -0600
From:      "Wes Peters" <wes@softweyr.com>
To:        "Assar Westerlund" <assar@FreeBSD.org>
Cc:        "Brian Somers" <brian@Awfulhak.org>, <cvs-committers@FreeBSD.org>, <cvs-all@FreeBSD.org>
Subject:   Re: cvs commit: src/lib/libutil ecalloc.c emalloc.3 emalloc.c erealloc.c estrdup.c Makefile libutil.h
Message-ID:  <001c01c1133a$f2b9ac50$24b244cc@blabber>
References:  <3698025593.995835470@blabber> <5lwv508huv.fsf@assaris.sics.se>

next in thread | previous in thread | raw e-mail | index | archive | help
Assar Westerlund wrote:
> Wes Peters <wes@softweyr.com> writes:
> >
> > I'd rather see such a library in a port/package.  Sure, the emalloc
> > etc., might help clarify applications, but like Brian I'm not convinced
> > they need to be in our standard library.
> 
> But this function (emalloc) is used and included in lots of the
> programs in the tree.  Since you're not likely suggesting we make them
> dependent of a port/package, should we keep copies of this function
> everywhere or should we just inline it?

Perhaps "libe"??

I agree with Alfred, I really don't like the idea of a program exiting 
willy-nilly and feel this will encourage developers to do so.  It is 
marginally better than not testing return values at all, and hoping 
for a core file, but only marginally so.  The fact that it has been 
done alot in existing code doesn't make it a good practice, just a
common one.

    - Wes


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe cvs-all" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?001c01c1133a$f2b9ac50$24b244cc>