On Tue, 13 May 2025 12:34:01 GMT, Chen Liang <li...@openjdk.org> wrote:

>> src/java.base/share/classes/java/io/InputStreamReader.java line 59:
>> 
>>> 57:  *     new InputStreamReader(System.in, 
>>> System.getProperty("stdin.encoding"));
>>> 58:  * }
>>> 59:  *
>> 
>> There are several places in the sources that still contain `new 
>> InputStreamReader(System.in)`. Shouldn't they be replaced with `new 
>> InputStreamReader(System.in, System.getProperty("stdin.encoding"))` too?)
>
> How did you search for those sources? I searched for literal `System.in` and 
> my comments are the only ones I could find in the JDK.

@liach, regex already reveals some, after tweaking it enough to eliminate false 
positives. 😅  `CTRL+Click`'ing on `InputStreamReader::new(InputStream)` gives 
an exhaustive list short enough to skim through.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/25155#discussion_r2087471334

Reply via email to