RFR: 8287541: Files.writeString fails to throw IOException for charset "windows-1252"

Alan Bateman alanb at openjdk.java.net
Fri Jun 3 20:14:22 UTC 2022


On Fri, 3 Jun 2022 16:48:46 GMT, Naoto Sato <naoto at openjdk.org> wrote:

> The code path calls `String.getBytesNoRepl()`, but it blindly replaces unmappable characters with replacements if the encoder is an `ArrayEncoder`. Changed only to do so if `doReplace` is `true` in `String.encodeWithEncoder()`.

Marked as reviewed by alanb (Reviewer).

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

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


More information about the core-libs-dev mailing list