Bug 1196391

Summary: "locale -a" produces incorrectly encoded output for bokmål.
Product: [Fedora] Fedora Reporter: Van de Bugger <van.de.bugger>
Component: glibcAssignee: Carlos O'Donell <codonell>
Status: CLOSED DUPLICATE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: medium Docs Contact:
Priority: unspecified    
Version: 21CC: arjun.is, codonell, fweimer, jakub, law, pfrankli, spoyarek
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Linux   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2015-03-05 22:09:16 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:

Description Van de Bugger 2015-02-25 21:44:32 UTC
Description of problem:

In Fedora 21 there are two locales: bokmal and bokmål (the second one includes U+00E5 character, "a" with ring above). (One of them is probably an alias.)

"locale -a" prints "bokmål" incorrectly: its outputs is always ISO-8859 text ("å" encoded as byte E5), regardless of current locale.

It has some unwanted effects. For example, "grep" treats "locale -a" output as a binary file:

    $ locale -a | grep en_US
    Binary file (standard input) matches

If current locale is an UTF-8 one, I would expect "locale -a" prints correct UTF-8 text ("å" encoded as two bytes C3 A5), not ISO-8859.

Version-Release number of selected component (if applicable):

Fedora 21
glibc-common-2.20-7.fc21.x86_64

How reproducible:

Always

Steps to Reproduce:

1. unset all LC_* environment variables, if any.
2. export LANG=en_US.utf8 (or any other UTF-8 locale)
3. locale -a > locales.txt
4. file locales.txt

Actual results:

locales.txt: ISO-8859 text

Expected results:

locales.txt: UTF-8 Unicode text

Comment 1 Carlos O'Donell 2015-03-05 22:09:16 UTC

*** This bug has been marked as a duplicate of bug 1184168 ***