RFR: 8245036: DataInputStream.readFully(byte[], int, int) does not throw expected IndexOutOfBoundsExceptions
Brian Burkhalter
brian.burkhalter at oracle.com
Thu Aug 6 20:09:10 UTC 2020
> On Aug 6, 2020, at 12:36 PM, Raffaello Giulietti <raffaello.giulietti at gmail.com> wrote:
>
>> This looks all right. I would be inclined to do like in [1] and throw the RuntimeException on the line after each readFully() and drop the return statements], but I’m not going to insist on it.
>> Thanks,
>> Brian
>> [1] http://hg.openjdk.java.net/jdk/jdk/file/db6952bf8c39/test/jdk/java/nio/file/etc/MacVolumesTest.java#l58 <http://hg.openjdk.java.net/jdk/jdk/file/db6952bf8c39/test/jdk/java/nio/file/etc/MacVolumesTest.java#l58>
>
> Sorry, I didn't completely get that.
> Here we are!
This looks good. I observed however that the test passes without the change to DataInputStream.
Brian
More information about the core-libs-dev
mailing list