qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] QEMU produces invalid JSON due to locale-dependent code


From: Eric Blake
Subject: Re: [Qemu-devel] QEMU produces invalid JSON due to locale-dependent code
Date: Mon, 24 Aug 2015 14:27:57 -0600
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:38.0) Gecko/20100101 Thunderbird/38.1.0

On 08/24/2015 11:56 AM, Daniel P. Berrange wrote:

>> (C) Run in a mixed locale
>>
>>     Whenever something breaks, we switch another LC_ to the C locale.
>>
>>     Can partially break GTK's internationalization.
>>
>> I happily concede that (A) would be best.  Until the manpower to pull it
>> off appears, I recommend (B), because it's safer than (C), and avoids
>> inconsistent localization, such as German messages combined with
>> non-German number formatting.
> 
> It seems the only thing that we really care about being localized is
> the messages catalogue, so the GTK UI gets internationalization in
> its menus / dialogs / etc. As such I think that we should do the
> opposite of (C). ie run every LC_* in the C locale, except for
> LC_MESSAGES which we allow to be localized.
> 
> This avoids any unpredictable functional consequences (like number
> formatting) while still giving user decent localization in the UI

Except that the LC_MESSAGES catalog may include messages such as "blah
%d blah" that get translated for use as a printf argument, and the lack
of matching LC_NUMERIC will make the translation look wrong.
Translators often assume that their translation is being used with
everything else about the locale matching the locale of the translation.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature


reply via email to

[Prev in Thread] Current Thread [Next in Thread]