[krbdev.mit.edu #7192] klist does not use localized time formatting
Benjamin Kaduk via RT
rt-comment at krbdev.mit.edu
Fri Jul 6 14:11:59 EDT 2012
[kaduk at MIT.EDU - Fri Jul 6 14:07:50 2012]:
>
> Enable all localizations in main functions
>
> Bite the bullet and pass LC_ALL to setlocale() instead of just
> LC_MESSAGES. Calls to setlocale() itself were introduced in
> fabbf9e443459e8c0161c84563690ed70c7f6a61 for ticket 6918, but
> only for LC_MESSAGES since only localized strings were needed
> and that was the most conservative option.
> However, klist, kadmin, and kinit (and perhaps others) would benefit
> from localized formats for times (i.e., LC_TIME). If potentially
> localized data is being sent on the wire, that is a bug that should
> be fixed. No such bugs are found with the current test suite, so we
> are comfortable enabling LC_ALL at this time.
The patch changes the test suite to force LC_ALL=C, so it is
unsurprising that the tests still pass when the user running 'make
check' has alternate locale settings.
As an additional and more useful check, I altered the tests to only
force LC_MESSAGES=C, and ran the test suite with
LC_{TIME,NUMERIC,COLLATE,CTYPE,MONETARY} set to both fr_FR.UTF-8 and
zh_CN.UTF-8; the tests still passed.
More information about the krb5-bugs
mailing list