bsdtar breakage ?
Peter Wemm
peter at wemm.org
Mon Nov 8 18:12:03 PST 2004
On Sunday 07 November 2004 10:15 am, Tim Kientzle wrote:
> Poul-Henning Kamp wrote:
> > i386 -current buildworld:
> >
> > ===> gnu/usr.bin/tar (all)
> > /bang/src1/src/gnu/usr.bin/tar/../../../contrib/tar/src/create.c:
> > In function `mode_to_chars':
> > /bang/src1/src/gnu/usr.bin/tar/../../../contrib/tar/src/create.c:26
> >4: warning: comparison is always false due to limited range of data
> > type ===> gnu/usr.bin/tar/doc (all)
> > ===> gnu/usr.bin/texinfo (all)
>
> This is gtar.
>
> The relevant code here is:
> mode_t v;
> int negative;
> negative = v < 0;
>
> Since mode_t is unsigned, the comparison
> "v < 0" is always false, hence the warning.
>
> This file hasn't been touched in over two years.
> mode_t has been unsigned for at least that long.
>
> I smell a compiler upgrade. ;-)
The funny thing, is that back in '92 or so, the AT&T SVR4 C compiler
drove me nuts because of useless warnings like this. I put a lot of
effort into getting gcc going on my machines, even though it was slower
to build etc. And it seems things are finally coming full circle.. gcc
is now just about as picky and uselessly pedantic as the AT&T compiler
was back then. Except now it is about 50 times slower. :-]
--
Peter Wemm - peter at wemm.org; peter at FreeBSD.org; peter at yahoo-inc.com
"All of this is for nothing if we don't go to the stars" - JMS/B5
More information about the freebsd-current
mailing list