RFR: 8272352: Java launcher can not parse Chinese character when system locale is set to UTF-8 [v2]

Naoto Sato naoto at openjdk.java.net
Tue May 3 18:55:55 UTC 2022


On Tue, 3 May 2022 16:17:00 GMT, Roger Riggs <rriggs at openjdk.org> wrote:

>> Naoto Sato has updated the pull request incrementally with one additional commit since the last revision:
>> 
>>   Default to UTF-8 if malloc fails
>
> src/java.base/windows/native/libjava/java_props_md.c line 695:
> 
>> 693:                            &display_encoding);
>> 694: 
>> 695:             sprops.sun_jnu_encoding = getEncodingInternal(0);
> 
> How should NULL from `getEncodingInternal` be handled?  (only if malloc fails).
> Perhaps just it should return the literal "UTF-8".

Fixed as suggested.

-------------

PR: https://git.openjdk.java.net/jdk/pull/8434


More information about the core-libs-dev mailing list