-
Bug
-
Resolution: Fixed
-
P4
-
11, 14
Issue | Fix Version | Assignee | Priority | Status | Resolution | Resolved In Build |
---|---|---|---|---|---|---|
JDK-8263520 | 13.0.7 | Ekaterina Vergizova | P4 | Resolved | Fixed | b04 |
JDK-8262228 | 11.0.11 | Patrick Concannon | P4 | Resolved | Fixed | b04 |
import java.net.SocketAddress;
import java.nio.ByteBuffer;
import java.nio.channels.ServerSocketChannel;
import java.nio.channels.SocketChannel;
public class NIOTest {
public static void main(String[] args) throws Exception {
ServerSocketChannel server = ServerSocketChannel.open();
server.bind(null);
SocketAddress saddr = server.getLocalAddress();
SocketChannel client = SocketChannel.open(saddr);
System.out.println(client);
client.close();
ByteBuffer buf = ByteBuffer.wrap("Hello world".getBytes());
client.write(buf);
}
}
throws AsynchronousCloseException instead of ChannelClosedException
import java.nio.ByteBuffer;
import java.nio.channels.ServerSocketChannel;
import java.nio.channels.SocketChannel;
public class NIOTest {
public static void main(String[] args) throws Exception {
ServerSocketChannel server = ServerSocketChannel.open();
server.bind(null);
SocketAddress saddr = server.getLocalAddress();
SocketChannel client = SocketChannel.open(saddr);
System.out.println(client);
client.close();
ByteBuffer buf = ByteBuffer.wrap("Hello world".getBytes());
client.write(buf);
}
}
throws AsynchronousCloseException instead of ChannelClosedException
- backported by
-
JDK-8262228 (sc) SocketChannel.read/write throws AsynchronousCloseException on closed channel
- Resolved
-
JDK-8263520 (sc) SocketChannel.read/write throws AsynchronousCloseException on closed channel
- Resolved
- relates to
-
JDK-8198562 (ch) Separate blocking and non-blocking code paths (part 1)
- Resolved
-
JDK-6878250 (so) IllegalBlockingModeException thrown when reading from a closed SocketChannel's InputStream
- Resolved
(1 links to)