On Wed, 22 Mar 2023 10:17:36 GMT, Per Minborg <pminb...@openjdk.org> wrote:

> > Nice idea. Just wonder could we do the same for `BufferedInputStream`?
> 
> I think it is doable but would require some more work as nullity is used as a 
> "closed flag".

I would nervous about changing BIS. The buf field is a protected field so lazy 
creating the array would lead to sub-classes throwing NPE or assuming the 
stream is closed. The closed state, the subclass in Process, and changing 
when/where OOME might be thrown are other considerations.

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

PR Comment: https://git.openjdk.org/jdk/pull/13121#issuecomment-1481127986

Reply via email to