RFR of 8180451: ByteArrayInputStream should override readAllBytes, readNBytes, and transferTo

Brian Burkhalter brian.burkhalter at oracle.com
Wed Mar 14 16:39:06 UTC 2018


On Mar 14, 2018, at 9:27 AM, David Lloyd <david.lloyd at redhat.com> wrote:

> +    public synchronized long transferTo(OutputStream out) throws IOException {
> +        int len = count - pos
> +        out.write(but, pos, len);
> 
> s/but/buf/ I guess?

Yes, I already caught that myself. I think I generated the webrev before running tests, i.e., out of sequence.

Thanks,

Brian

> 
> +        pos = count;
> +        return len;
> +    }
> +



More information about the core-libs-dev mailing list