Date: 23 Jul 2001 14:21:18 +0200 From: Assar Westerlund <assar@FreeBSD.org> To: Poul-Henning Kamp <phk@critter.freebsd.dk> Cc: 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: <5l66cjx2dd.fsf@assaris.sics.se> In-Reply-To: Poul-Henning Kamp's message of "Mon, 23 Jul 2001 08:43:05 %2B0200" References: <28513.995870585@critter>
next in thread | previous in thread | raw e-mail | index | archive | help
Poul-Henning Kamp <phk@critter.freebsd.dk> writes: > Why not simply use: > > char *_malloc_options = "X"; > > as documented in malloc(3) ? Because it's not portable. If you want to build FreeBSD code on other platforms (such as I believe both Brian and Garance wanted to) you cannot rely on their malloc having that option. You can have your code call non-portabel functions (such as strdup, snprintf, asprintf, err, emalloc, and what have you) if you build a portabel library with these functions for use on platforms where they aren't provided to you. /assar 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?5l66cjx2dd.fsf>