On Wed, 5 Nov 2025 18:14:44 GMT, Brian Burkhalter <[email protected]> wrote:
> Add a system property, `jdk.io.File.failIfEmptyPath`, which when `true` > reverts to legacy, pre-JDK 25 behavior, as to how `java.io.File` handles an > empty pathname string. The implementation modification which resolved [JDK-8024695](https://bugs.openjdk.org/browse/JDK-8024695) caused a `java.io.File` created from the empty string `""` to be treated as if the file was created from the pathname string of the current working directory, `System.getProperty("user.dir")`. This change caused failures in code which relied on the inconsistent, undocumented behavior. ------------- PR Comment: https://git.openjdk.org/jdk/pull/28158#issuecomment-3492681612
