On Tue, 25 Aug 2026 17:46:19 GMT, Markus KARG <[email protected]> wrote:

>> This Pull Request provides an implementation for 
>> [JDK-8389573](https://bugs.openjdk.org/browse/JDK-8389573): 
>> 'InputStreamReader.readAllAsString() should override the generic Reader 
>> default implementation to avoid unnecessary buffer copies'.
>> 
>> ---------
>> - [x] I confirm that I make this contribution in accordance with the 
>> [OpenJDK Interim AI Policy](https://openjdk.org/legal/ai).
>
> Markus KARG has updated the pull request incrementally with one additional 
> commit since the last revision:
> 
>   Simplified approach by Alan Bateman

src/java.base/share/classes/sun/nio/cs/StreamDecoder.java line 198:

> 196:     private static CharBuffer ensureFree(CharBuffer cb, int minFree) {
> 197:         return cb.remaining() < minFree ? 
> CharBuffer.allocate(cb.position() + minFree).put(cb.flip()) : cb;
> 198:     }

I assume this is not needed now.

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

PR Review Comment: https://git.openjdk.org/jdk/pull/32264#discussion_r3874053809

Reply via email to