GNU bug report logs -
#9612
sort: avoid a NaN-induced infloop
Previous Next
Reported by: Jim Meyering <jim <at> meyering.net>
Date: Tue, 27 Sep 2011 14:50:02 UTC
Severity: normal
Done: Jim Meyering <jim <at> meyering.net>
Bug is archived. No further changes may be made.
Full log
Message #34 received at 9612-done <at> debbugs.gnu.org (full text, mbox):
Jim Meyering wrote:
> Jim Meyering wrote:
>> Who would have thought that including a few NaNs in the input to sort
>> would make it infloop.
>>
>> The original failure arose only when sort was reading from a pipe:
>>
>> yes -- -nan | head -156903 | sort -g > /dev/null
>>
>> But it's not always easy to reproduce.
> ...
>> [ I'm about to file the glibc bug
> ...
>
> I've done that:
>
> RFE: strtold: do not include uninitialized bytes when converting "NaN"
> http://sourceware.org/bugzilla/show_bug.cgi?id=13246
In the above BZ comments, Jakub Jelinek proposed something more robust,
but I think it's not necessary. If we find an optimizer that thinks the
added memset is useless, we'll discover it via the failing test, so I'd
prefer not to add the volatile/union hack.
I'm closing this.
This bug report was last modified 13 years and 228 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.