<i18n dev> [13] RFR: 8220227: Host Locale Provider getDisplayCountry returns error message under non-English Win10

Toshio 5 Nakamura TOSHIONA at jp.ibm.com
Mon Mar 11 08:57:11 UTC 2019


Hi Naoto-san,

Thank you for reviewing the fix.
Could you re-review the updated webrev?

http://cr.openjdk.java.net/~tnakamura/8220227/webrev.01/

Thanks,
Toshio Nakamura

naoto.sato at oracle.com wrote on 2019/03/09 02:39:48:

> From: naoto.sato at oracle.com
> To: Toshio 5 Nakamura <TOSHIONA at jp.ibm.com>, 18n-dev <i18n-
> dev at openjdk.java.net>, core-libs-dev <core-libs-dev at openjdk.java.net>
> Date: 2019/03/09 02:39
> Subject: Re: <i18n dev> [13] RFR: 8220227: Host Locale Provider
> getDisplayCountry returns error message under non-English Win10
>
> Hi Nakamura-san,
>
> Thanks for fixing this. Since it is using a heuristic way to detect
> "unknown", I'd use String.endsWith() instead of String.contains() both
> in HostLocaleProviderAdapterImpl.java and LocaleProviders.java, which
> would be more accurate.
>
> Naoto
>
> On 3/7/19 10:25 PM, Toshio 5 Nakamura wrote:
> >
> > Hi,
> >
> > Could you review this fix? I'd like to have a sponsor of it, since I'm
an
> > author.
> >
> > Bug: https://urldefense.proofpoint.com/v2/url?
>
u=https-3A__bugs.openjdk.java.net_browse_JDK-2D8220227&d=DwICaQ&c=jf_iaSHvJObTbx-

> siA1ZOg&r=EVbFABcgo-X99_TGI2-qsMtyulHUruf8lAzMlVpVRqw&m=cWI02BT4Ii--
>
XvWPkl7JnE5M_ShlPLTERbtkTMMn1mU&s=8UA5DKmhd3SIIZmsX8JNOvaQ5wxcIq5bwdtHAnZLsPU&e=

> > Webrev: https://urldefense.proofpoint.com/v2/url?
> u=http-3A__cr.openjdk.java.net_-7Etnakamura_8220227_webrev.
> 00_&d=DwICaQ&c=jf_iaSHvJObTbx-siA1ZOg&r=EVbFABcgo-X99_TGI2-
> qsMtyulHUruf8lAzMlVpVRqw&m=cWI02BT4Ii--
> XvWPkl7JnE5M_ShlPLTERbtkTMMn1mU&s=kLSymGjxW5MrGtWY3zs7VEdg1BN6nYGQjue1w-
> nPs7c&e=
> >
> > Issue:
> > Under Windows 10 non-English, Locale.getDisplayCountry() shows an error
> > message,
> > if Host Locale Provider is used (-Djava.locale.providers=HOST).
> >
> > Fix proposal:
> > The current code compares "Unknown Region (" with the result, but it
could
> > be translated.
> > I believe we can compare it with "("+RegionCode+")", which covers all
38
> > Language
> > Packs of Windows Server 2016.
> >
> > Thanks,
> > Toshio Nakamura
> >
>


More information about the core-libs-dev mailing list