On Sun, 1 May 2022 04:51:17 GMT, Ichiroh Takiguchi <itakigu...@openjdk.org> wrote:
>> On JDK19 with Linux ja_JP.eucjp locale, >> System.getenv() returns unexpected value if environment variable has >> Japanese EUC characters. >> It seems this issue happens because of JEP 400. >> Arguments for ProcessBuilder have same kind of issue. > > Ichiroh Takiguchi has updated the pull request incrementally with one > additional commit since the last revision: > > 8285517: System.getenv() returns unexpected value if environment variable > has non ASCII character test/jdk/java/lang/System/i18nEnvArg.java line 63: > 61: } > 62: > 63: public static class Start { Do we need `Start` class? Can it be merged with the parent to reduce the complexity? test/jdk/java/lang/System/i18nEnvArg.java line 87: > 85: System.getProperty("java.class.path"), > 86: "i18nEnvArg$Verify", > 87: EUC_JP_TEXT); Can utilize `ProcessTools` class. test/jdk/java/lang/System/i18nEnvArg.java line 130: > 128: environ_mid.setAccessible(true); > 129: byte[][] environ = (byte[][]) environ_mid.invoke(null, > 130: (Object[])null); I am not sure I like this piece, invoking a package private method of `ProcessEnvironment` class. Can we simply verify the result of `System.getenv(EUC_JP_TEXT)`? ------------- PR: https://git.openjdk.java.net/jdk/pull/8378