[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: bug in sort 2.0e
From: |
Jim Meyering |
Subject: |
Re: bug in sort 2.0e |
Date: |
Sun, 07 Oct 2001 20:05:21 +0200 |
User-agent: |
Gnus/5.090004 (Oort Gnus v0.04) Emacs/21.0.107 |
Bob Proulx <address@hidden> wrote:
> Peter
>
>> sort fails for me on the attached file. Here is all the version
>> information:
>
> Thanks for the report and for supplying all of the needed version
> information. That was great.
>
>> address@hidden oracle]$ sort --version
>> sort (GNU textutils) 2.0e
>>
>> address@hidden oracle]$ uname -a
>> Linux lsec2.epfl.ch 2.2.19-7.0.1 #1 Tue Apr 10 01:56:16 EDT 2001 i686
>> unknown
>> address@hidden oracle]$ sort lof
>> Segmentation fault (core dumped)
>
> Initially I was not able to recreate your problem. It worked fine for
> me using exactly the same version of sort, version 2.0e. But then I
> remembered the common problem that people have with LANG.
>
> sort lof
> [...works fine...]
>
> LANG=POSIX sort lof
> [...works fine...]
>
> LANG=en_US sort lof
> Segmentation fault
>
> You probably have LANG set to the en_US locale. Therefore I will
> forward you a canned reply concerning locale variables. Usually those
> will cause sort to produce incorrect output, not to crash. It does
> seem that regardless of locale setting that sort should not seg fault.
> Something to look into.
Thanks Peter and Bob.
It appears that the seg fault is the result of a bug in the strcoll
function from the GNU C library. It is fixed in newer versions. Sorry,
I don't have the precise version numbers. If someone can provide them,
I'd appreciate it, since this seems destined to become a FAQ.
If upgrading to a fixed libc isn't an option, you might want to
consider compiling out sort's use of strcoll, e.g., by doing
`./configure --disable-nls && make'.
BTW, you might want to get a newer version of the textutils.
The latest test release is here:
ftp://alpha.gnu.org/gnu/fetish/textutils-2.0.16.tar.gz