If I try to obtain a TCP socket's output stream after I close its input stream,
I get a null pointer exception. This is behaviour that I believe should not be
occurring.
To reproduce this problem, run the included test program. It should barf
as follows:
java.lang.NullPointerException
at java.io.FileInputStream.<init>(FileInputStream.java)
at java.net.SocketInputStream.<init>(SocketInputStream.java:50)
at java.net.PlainSocketImpl.getInputStream(PlainSocketImpl.java:394)
at java.net.Socket.getInputStream(Socket.java:290)
at test.suck.main(suck.java:18)
I get a null pointer exception. This is behaviour that I believe should not be
occurring.
To reproduce this problem, run the included test program. It should barf
as follows:
java.lang.NullPointerException
at java.io.FileInputStream.<init>(FileInputStream.java)
at java.net.SocketInputStream.<init>(SocketInputStream.java:50)
at java.net.PlainSocketImpl.getInputStream(PlainSocketImpl.java:394)
at java.net.Socket.getInputStream(Socket.java:290)
at test.suck.main(suck.java:18)
- duplicates
-
JDK-4035663 Sockets can not successfully close one side while continuing to use the other
-
- Resolved
-