From owner-cvs-all Sun Jul 22 22:43:25 2001 Delivered-To: cvs-all@freebsd.org Received: from softweyr.com (softweyr.com [208.247.99.111]) by hub.freebsd.org (Postfix) with ESMTP id 0FD8537B401; Sun, 22 Jul 2001 22:43:21 -0700 (PDT) (envelope-from wes@softweyr.com) Received: from blabber.softweyr.com ([204.68.178.36] helo=blabber) by softweyr.com with smtp (Exim 3.22 #1) id 15OYYz-0002jn-00; Sun, 22 Jul 2001 23:47:29 -0600 Message-ID: <001c01c1133a$f2b9ac50$24b244cc@blabber> From: "Wes Peters" To: "Assar Westerlund" Cc: "Brian Somers" , , References: <3698025593.995835470@blabber> <5lwv508huv.fsf@assaris.sics.se> Subject: Re: cvs commit: src/lib/libutil ecalloc.c emalloc.3 emalloc.c erealloc.c estrdup.c Makefile libutil.h Date: Sun, 22 Jul 2001 23:47:24 -0600 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.00.2919.6700 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6700 Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Assar Westerlund wrote: > Wes Peters 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