8067801: Enforce null check for underlying I/O streams
Alan Bateman
Alan.Bateman at oracle.com
Thu Jul 18 15:52:19 UTC 2019
On 17/07/2019 17:12, Brian Burkhalter wrote:
> https://bugs.openjdk.java.net/browse/JDK-8067801
> http://cr.openjdk.java.net/~bpb/8067801/webrev.00/
>
> Add null check to Filter{In,Out}putStream constructors. This covers all the cases listed in the issue as those are all subclasses of these two classes. No javadoc update is need due to this statement in the java.io package doc:
>
> "Unless otherwise noted, passing a null argument to a constructor or method in any class or interface in this package will cause a NullPointerException to be thrown."
>
>
I see this is has pushed but I think it will need to be re-examined
because the javadoc allows `in` and `out` to be specified as null and
set after the stream is created (the javadoc for the parameters
overrides the "Unless otherwise ..." text in the package description).
-Alan
More information about the core-libs-dev
mailing list