Package: coreutils
Version: 5.97-5.3
Severity: minor

The sort command appears to ignore (as in not include) locale punctuation when splitting data into fields. This has a side effect of causing a numeric sort to fail to correctly sort comma-separated files.

The following is a test demonstrating this:

$ export LANG=C
$ (echo 10#1;echo 1#10) | sort -n -t '#'
1#10
10#1
$ (echo 10,1;echo 1,10) | sort -n -t ','
1,10
10,1
$ export LANG=en_NZ.UTF-8
$ (echo 10#1;echo 1#10) | sort -n -t '#'
1#10
10#1
$ (echo 10,1;echo 1,10) | sort -n -t ','
10,1
1,10

Now that I'm aware that the locale is an issue, I can update my scripts to compensate, but this is a problem that is likely to bite other people who use the sort command for comma-separated files.

NOTE: This bug may be similar to others, #367891, #409221, #353909, and #223068. Please mark as duplicate if you do not think there is any additional issues identified by this bug.

--
David Hall (gringer)


--
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to