Date: Fri, 05 Jan 2001 20:27:17 +0000 From: Brian Somers <brian@Awfulhak.org> To: Ben Smithurst <ben@FreeBSD.org> Cc: Matt Dillon <dillon@earth.backplane.com>, Chris Faulhaber <jedgar@fxp.org>, Brian Somers <brian@Awfulhak.org>, cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org, brian@Awfulhak.org Subject: Re: cvs commit: src/usr.bin/apply apply.c Message-ID: <200101052027.f05KRHi48955@hak.lan.Awfulhak.org> In-Reply-To: Message from Ben Smithurst <ben@FreeBSD.org> of "Fri, 05 Jan 2001 19:44:29 GMT." <20010105194429.N85794@strontium.scientia.demon.co.uk>
next in thread | previous in thread | raw e-mail | index | archive | help
> Matt Dillon wrote: > > > :I don't agree with that, since the other functions return the number of > > :characters printed as well. > > > > Yes, but not portably. The ANSI standard tried to standardize it but > > the reality is that only snprintf()'s return value is portable. If you > > try to use the return value from other functions as a count, your code > > won't be portable. asprintf() *might* be portable too, but nothing else. > > Oh hell. In that case I'll probably just make the paragraph about > snprintf's return value clearer and not touch anything else. Except that the paragraph that says These functions return the number of characters printed (not including the trailing `\0' used to end output to strings). is wrong :-/ > -- > Ben Smithurst / ben@FreeBSD.org / PGP: 0x99392F7D > -- Brian <brian@Awfulhak.org> <brian@[uk.]FreeBSD.org> <http://www.Awfulhak.org> <brian@[uk.]OpenBSD.org> Don't _EVER_ lose your sense of humour ! 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?200101052027.f05KRHi48955>