From owner-cvs-all Fri Jan 5 11: 4:58 2001 From owner-cvs-all@FreeBSD.ORG Fri Jan 5 11:04:54 2001 Return-Path: Delivered-To: cvs-all@freebsd.org Received: from scientia.demon.co.uk (scientia.demon.co.uk [212.228.14.13]) by hub.freebsd.org (Postfix) with ESMTP id BEFEF37B402; Fri, 5 Jan 2001 11:04:50 -0800 (PST) Received: from strontium.scientia.demon.co.uk ([192.168.91.36] ident=root) by scientia.demon.co.uk with esmtp (Exim 3.20 #1) id 14EbmD-0003tW-00; Fri, 05 Jan 2001 18:39:45 +0000 Received: (from ben@localhost) by strontium.scientia.demon.co.uk (8.11.1/8.11.1) id f05Idiw54706; Fri, 5 Jan 2001 18:39:44 GMT (envelope-from ben) Date: Fri, 5 Jan 2001 18:39:43 +0000 From: Ben Smithurst To: Chris Faulhaber Cc: Brian Somers , cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/usr.bin/apply apply.c Message-ID: <20010105183943.L85794@strontium.scientia.demon.co.uk> References: <200101050206.f0526rB87964@hak.lan.Awfulhak.org> <20010105162917.K85794@strontium.scientia.demon.co.uk> <20010105120633.B66833@peitho.fxp.org> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010105120633.B66833@peitho.fxp.org> Sender: ben@scientia.demon.co.uk Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Chris Faulhaber wrote: > On Fri, Jan 05, 2001 at 04:29:17PM +0000, Ben Smithurst wrote: >> Would this change make you feel better? >> >> change this: >> >> Snprintf() and vsnprintf() will write at most size-1 of the characters >> printed into the output string (the size'th character then gets the ter- >> minating `\0'); if the return value is greater than or equal to the size >> argument, the string was too short and some of the printed characters >> were discarded. >> >> to this: >> >> Snprintf() and vsnprintf() will write at most size-1 of the characters >> printed into the output string (the size'th character then gets the ter- >> minating `\0'), and return the number of characters written to the >> buffer, excluding the terminating `\0'. This value may be less than the >> number of characters which would have been written, had the buffer been >> large enough; if the return value is greater than or equal to the size >> argument, the string was too short and some of the printed characters >> were discarded. >> > > This change makes sense. Well no, it doesn't actually, I'm not sure what I was on when I wrote it. "This value may be less than the number of characters which would have been written" That's such rubbish I can't believe I wrote it. I'll try again when I've woken up properly, perhaps. :-/ -- Ben Smithurst / ben@FreeBSD.org / PGP: 0x99392F7D To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message