On 02/ 8/10 02:20 PM, Dave Miner wrote:
>
>>>
>>> text-mode-menu.ksh, 49: The comment says LC_ALL, but you're in fact
>>> setting the individual elements, as well as LANG.  One or the other is
>>> incorrect, and LANG would seem to be unnecessary, period.
>>
>> I'll update the comment. Setting LC_ALL is the wrong choice, as it
>> overrides all the other LC_* variables (which has implications for a
>> user dropping to the shell to run other utilities - admittedly not an
>> '80% case,' but that's the reason).
>>
>> Setting LANG, and LANG alone, is what I believe to be the correct
>> choice. LANG is the variable that's checked when the relevant LC_
>> variable is not set. As I understand it, for example, if a program is
>> doing numerical formatting and needs to know whether to use a comma or a
>> period as the decimal point, first LC_ALL is checked; if that's not set,
>> then LC_NUMERIC is checked; if that's not set, then LANG is checked; if
>> that's not set, then the system default is used.[1] If that's the case,
>> then for a service like this that is providing a 'starting point', only
>> LANG needs to be set.
>>
>> [1]http://www.opengroup.org/onlinepubs/007908799/xbd/envvar.html (See
>> section "Internationalisation Variables")
>
> Sure, I'll accept LANG.  setlocale(3c) is the local reference on 
> evaluation order, BTW.
>
> Dave

Ok, I'll update to just set LANG. (environ(5) also confirms this).

An updated webrev will be out after addressing comments from others.

Thanks,
Keith

Reply via email to