Integrated: 8275149: (ch) ReadableByteChannel returned by Channels.newChannel(InputStream) throws ReadOnlyBufferException

Brian Burkhalter bpb at openjdk.java.net
Fri Oct 15 23:01:57 UTC 2021


On Tue, 12 Oct 2021 17:56:59 GMT, Brian Burkhalter <bpb at openjdk.org> wrote:

> This small change would modify `java.nio.channels.Channels$ReadableByteChannelImpl.read(ByteBuffer)` to throw an `IllegalArgumentException` if the `ByteBuffer` parameter is read-only as required by its specification instead of the `ReadOnlyBufferException` currently thrown.

This pull request has now been integrated.

Changeset: 7fc3a8d0
Author:    Brian Burkhalter <bpb at openjdk.org>
URL:       https://git.openjdk.java.net/jdk/commit/7fc3a8d052bfb8d31fedec56f72b10a40ba7bf83
Stats:     12 lines in 2 files changed: 10 ins; 0 del; 2 mod

8275149: (ch) ReadableByteChannel returned by Channels.newChannel(InputStream) throws ReadOnlyBufferException

Reviewed-by: alanb

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

PR: https://git.openjdk.java.net/jdk/pull/5914


More information about the nio-dev mailing list