Bruno Haible <bruno <at> clisp.org> writes:

> 
> On FreeBSD 6.1, printf of "%010a" of Infinity and NaN yields
> "0000000inf" and "0000000nan", respectively.
> 
> While on glibc systems, it yields
> "       inf" and "       nan", respectively.
> 
> I find glibc's output more sensible, since strtod will accept it, while
> strtod will not grok "0000000inf". But FreeBSD appears to be closer to
> the POSIX wording, I won't count it as a FreeBSD bug.

The Austin group answered by referring to C99 (the POSIX spec defers to C99 in 
this matter):

http://lists.gnu.org/archive/html/bug-gnulib/2007-04/msg00107.html

FreeBSD 6.1 is buggy.  Can we please revert this patch, and instead catch the 
FreeBSD bug during ./configure?

> 
> 2007-04-04  Bruno Haible  <bruno <at> clisp.org>
> 
>       * tests/test-vasnprintf-posix.c (test_function): Allow two possible
>       results for "%010a" of Infinity and NaN.
...
>       Needed for FreeBSD 6.1.

-- 
Eric Blake





Reply via email to