From owner-freebsd-audit Wed Jul 18 7:52:26 2001 Delivered-To: freebsd-audit@freebsd.org Received: from ringworld.nanolink.com (ringworld.nanolink.com [195.24.48.39]) by hub.freebsd.org (Postfix) with SMTP id ECCCA37B407 for ; Wed, 18 Jul 2001 07:52:22 -0700 (PDT) (envelope-from roam@orbitel.bg) Received: (qmail 68155 invoked by uid 1000); 18 Jul 2001 14:56:37 -0000 Date: Wed, 18 Jul 2001 17:56:37 +0300 From: Peter Pentchev To: Mike Barcroft Cc: Alexey Zelkin , audit@FreeBSD.org, Dag-Erling Smorgrav Subject: Re: whois(1) changes Message-ID: <20010718175637.D29731@ringworld.oblivion.bg> Mail-Followup-To: Mike Barcroft , Alexey Zelkin , audit@FreeBSD.org, Dag-Erling Smorgrav References: <20010717214524.A51455@coffee.q9media.com> <20010718154425.A65945@phantom.cris.net> <20010718110051.A52720@coffee.q9media.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: <20010718110051.A52720@coffee.q9media.com>; from mike@FreeBSD.org on Wed, Jul 18, 2001 at 11:00:51AM -0400 Sender: owner-freebsd-audit@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Wed, Jul 18, 2001 at 11:00:51AM -0400, Mike Barcroft wrote: > On Wed, Jul 18, 2001 at 03:44:25PM +0300, Alexey Zelkin wrote: > > On Tue, Jul 17, 2001 at 09:45:24PM -0400, Mike Barcroft wrote: > > > whois.20010717.patch > > > > > > o Reintegrate part of phantom's patch which adds gethostinfo(). > > > o Create a wrapper for asprintf(3) which checks for failure. > > > o Tested on i386, alpha. > > > > [patch skiped] > > > > 1. isdigit()'s argument should be explicitly casted to 'unsigned char' per > > ache's guidelines. > > Can you explain this in more detail? To my understanding, one only does > this when using setlocale(3) and friends. It's only the sane thing to do. Someone, some day, may decide to go ahead and make whois(1) locale-aware. You might as well make their job easier by using (logically correct) unsigned char arguments to functions that accept characters as opposed to arbitrary integer values. (And then somebody in the audience mutters something about multibyte characters and wchar_t, and I hastily scurry back into the hole I crawled out of.. ;) G'luck, Peter -- This sentence was in the past tense. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-audit" in the body of the message