Return-Path: Delivered-To: apmail-apr-dev-archive@www.apache.org Received: (qmail 1737 invoked from network); 30 Nov 2004 15:28:33 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur-2.apache.org with SMTP; 30 Nov 2004 15:28:33 -0000 Received: (qmail 65924 invoked by uid 500); 30 Nov 2004 15:27:11 -0000 Delivered-To: apmail-apr-dev-archive@apr.apache.org Received: (qmail 65879 invoked by uid 500); 30 Nov 2004 15:27:10 -0000 Mailing-List: contact dev-help@apr.apache.org; run by ezmlm Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: Delivered-To: mailing list dev@apr.apache.org Received: (qmail 65844 invoked by uid 99); 30 Nov 2004 15:27:10 -0000 X-ASF-Spam-Status: No, hits=0.0 required=10.0 tests= X-Spam-Check-By: apache.org Received-SPF: pass (hermes.apache.org: local policy) Date: Tue, 30 Nov 2004 10:26:31 -0500 (EST) From: Cliff Woolley X-X-Sender: jcw5q@cobra.cs.Virginia.EDU To: Jeff Trawick cc: dev@apr.apache.org Subject: Re: svn commit: r107007 - /apr/apr/trunk/CHANGES /apr/apr/trunk/include/apr_lib.h /apr/apr/trunk/passwd/apr_getpass.c In-Reply-To: Message-ID: References: <20041130144133.68456.qmail@minotaur.apache.org> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-Virus-Checked: Checked X-Spam-Rating: minotaur-2.apache.org 1.6.2 0/1000/N On Tue, 30 Nov 2004, Jeff Trawick wrote: > > * @param pwbuf Buffer to store the password > > * @param bufsize The length of the password buffer. > > + * @remark If the password entered must be truncated to fit in > > + * the provided buffer, APR_ENAMETOOLONG will be returned. > > */ > > APR_DECLARE(apr_status_t) apr_password_get(const char *prompt, char *pwbuf, > > apr_size_t *bufsize); > > another disturbance: we force caller to go to the trouble to pass by > address, but we don't update the size on output to indicate either the > number of bytes stored or the number of bytes needed; shrug or "fix"? By number of bytes stored, I assume you mean bytes stored in the non-error case, since bytes stored in the error case would just be bufsize. Right? If that's the case, then it's maybe worth fixing but I'm not sure I care. How many bytes would be needed seems to make somewhat more sense as being a useful value, but do we have any other functions that work that way?