8246707: (sc) SocketChannel.read/write throws AsynchronousCloseException on closed channel

This fix addresses an issue where an AsynchronousCloseException was being thrown instead of a ChannelClosedException when SocketChannel.write() is called on a closed SocketChannel.

Reviewed-by: alanb, chegar, dfuchs, clanger
2 files changed