Date: Wed, 11 Sep 2002 13:47:16 -0400 From: Mike Barcroft <mike@FreeBSD.org> To: John Baldwin <jhb@FreeBSD.org> Cc: cvs-all@FreeBSD.ORG, cvs-committers@FreeBSD.ORG, fanf@FreeBSD.ORG, Kimura Fuyuki <fuyuki@hadaly.org> Subject: Re: cvs commit: src/usr.bin/uudecode uudecode.c Message-ID: <20020911134716.A84338@espresso.q9media.com> In-Reply-To: <XFMail.20020911130920.jhb@FreeBSD.org>; from jhb@FreeBSD.org on Wed, Sep 11, 2002 at 01:09:20PM -0400 References: <20020911002338.A73618@espresso.q9media.com> <XFMail.20020911130920.jhb@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
John Baldwin <jhb@FreeBSD.org> writes: > > On 11-Sep-2002 Mike Barcroft wrote: > > Kimura Fuyuki <fuyuki@hadaly.org> 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
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20020911134716.A84338>