RFR: 8366911: (fs) Remove support for normalizing file names to Unicode normalized form D (macOS)

Alan Bateman alanb at openjdk.org
Fri Sep 5 06:47:11 UTC 2025


On Thu, 4 Sep 2025 22:45:57 GMT, Brian Burkhalter <bpb at openjdk.org> wrote:

> Remove all code for normalizing file paths to Unicode Normalization Format D on macOS. This removes support for the system property `jdk.nio.path.useNormalizationFormD`. This change nullifies the effect of the change made for [JDK-8289689](https://bugs.openjdk.org/browse/JDK-8289689).

src/java.base/unix/classes/sun/nio/fs/UnixPath.java line 816:

> 814:         String stringValue = this.stringValue;
> 815:         if (stringValue == null) {
> 816:             this.stringValue = stringValue = Util.toString(path);     // platform encoding

In passing, I think stringValue can be a stable field.

test/jdk/java/nio/file/Path/MacPathTest.java line 25:

> 23: 
> 24: /* @test
> 25:  * @bug 7130915 8289689 8366911

This test has `@run main/othervm -Djdk.nio.path.useNormalizationFormD=true` that I assume should be removed.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/27109#discussion_r2324245004
PR Review Comment: https://git.openjdk.org/jdk/pull/27109#discussion_r2324244091


More information about the nio-dev mailing list