Subject: bug#9780: sort -u throws out non-duplicates

From: Bernhard Rosenkraenzer <[email-masked]>
Date: Tue, 18 Oct 2011 02:02:57 +0100

On Tue, 18 Oct 2011 01:59:12 +0100, Bernhard Rosenkraenzer wrote:
> Note the missing .../java/java/security/cert/X509Certificate.java
>
> The problem occurs (at least) with sort from coreutils 8.12, 8.13 and 
> 8.14.

This is locale related... Seems to happen in any non-C locale.

[bero@matterhorn ~]$ tr ' ' '\n' <java-source-list |LANG=C sort -u 
|grep X509Certificate
libcore/luni/src/main/java/java/security/cert/X509Certificate.java
libcore/luni/src/main/java/javax/security/cert/X509Certificate.java
[bero@matterhorn ~]$ tr ' ' '\n' <java-source-list |LANG=en_US sort -u 
|grep X509Certificate
libcore/luni/src/main/java/javax/security/cert/X509Certificate.java
[bero@matterhorn ~]$ tr ' ' '\n' <java-source-list |LANG=de_CH sort -u 
|grep X509Certificate
libcore/luni/src/main/java/javax/security/cert/X509Certificate.java
[bero@matterhorn ~]$ tr ' ' '\n' <java-source-list |LANG=fr_FR sort -u 
|grep X509Certificate
libcore/luni/src/main/java/javax/security/cert/X509Certificate.java