bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [OT] Is od broken?


From: Eric Blake
Subject: Re: [OT] Is od broken?
Date: Wed, 11 Jun 2008 20:43:46 +0000 (UTC)
User-agent: Loom/3.14 (http://gmane.org/)

Eric Blake <ebb9 <at> byu.net> writes:

> $  src/od -An -N48 configure -tfL
>  0.000000000000000000e+9999
>  0.000000000000000000e+9999
>  0.000000000000000000e+9999
>  0.000000000000000000e+9999
> 
> I'm not sure why cygwin is printing such a weird value for (invalid) long 
> doubles, but this patch didn't change the situation.  It seems like a NaN 
might 
> be better than 0.0...e+9999 if the random 12-byte sequence can't be converted 
> to a valid 10-byte register long double on x86.  Perhaps this is a bug in 
> gnulib's printf replacement?

This particular bug is in cygwin's libc.  Coreutils isn't using the gnulib 
printf-posix module, and therefore this is calling the native printf (which on 
cygwin is broken on long double) rather than the gnulib replacement.  Would it 
be worth updating bootstrap.conf to pull in the printf-posix module?  Or, since 
that would potentially bloat all of the coreutils binaries that use printf but 
not floating point by pulling in a replacement printf, would it be worth 
refactoring od.c to use xprintf or vasprintf (both of which already use the 
gnulib replacement) rather than printf?

-- 
Eric Blake







reply via email to

[Prev in Thread] Current Thread [Next in Thread]