From owner-cvs-all Wed Sep 11 10:53:45 2002 Delivered-To: cvs-all@freebsd.org Received: from mx1.FreeBSD.org (mx1.FreeBSD.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6808E37B400; Wed, 11 Sep 2002 10:53:40 -0700 (PDT) Received: from espresso.q9media.com (espresso.q9media.com [65.39.129.122]) by mx1.FreeBSD.org (Postfix) with ESMTP id D75DB43E42; Wed, 11 Sep 2002 10:53:39 -0700 (PDT) (envelope-from mike@espresso.q9media.com) Received: by espresso.q9media.com (Postfix, from userid 1002) id 8B9A59E5A; Wed, 11 Sep 2002 13:47:16 -0400 (EDT) Date: Wed, 11 Sep 2002 13:47:16 -0400 From: Mike Barcroft To: John Baldwin Cc: cvs-all@FreeBSD.ORG, cvs-committers@FreeBSD.ORG, fanf@FreeBSD.ORG, Kimura Fuyuki Subject: Re: cvs commit: src/usr.bin/uudecode uudecode.c Message-ID: <20020911134716.A84338@espresso.q9media.com> References: <20020911002338.A73618@espresso.q9media.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: ; from jhb@FreeBSD.org on Wed, Sep 11, 2002 at 01:09:20PM -0400 Organization: The FreeBSD Project Sender: owner-cvs-all@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG John Baldwin writes: > > On 11-Sep-2002 Mike Barcroft wrote: > > Kimura Fuyuki writes: > >> `n' can be minus... > >> > >> Index: uudecode.c > >> =================================================================== > >> RCS file: /home/ncvs/src/usr.bin/uudecode/uudecode.c,v > >> retrieving revision 1.39 > >> diff -u -r1.39 uudecode.c > >> --- uudecode.c 11 Sep 2002 01:00:56 -0000 1.39 > >> +++ uudecode.c 11 Sep 2002 02:59:47 -0000 > >> @@ -153,7 +153,7 @@ > >> decode2(void) > >> { > >> int base64; > >> - size_t n; > >> + int n; > >> char ch, *p, *q; > >> void *mode; > >> struct passwd *pw; > >> > > > > Unfortunately this wasn't good enough since most uses of n needed to > > be size_t. I've added a new variable to cope. It seems to build > > share, so hopefully world is unbroken again. Thanks for the pointer. > > I thought I checked all the uses of n, but didn't notice the last few. > > Erm, ssize_t? That's hackish to cram two unrelated temporary variables into one. It wouldn't be bad if they both needed to be the same type, but in this case there are really two separate needs for two separate types. Also, using ssize_t would require at least one additional cast to avoid a signed unsigned comparison. Best regards, Mike Barcroft To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message