8245121: (bf) XBuffer.put(Xbuffer src) can give unexpected result when storage overlaps

Brian Burkhalter brian.burkhalter at oracle.com
Fri May 15 18:33:06 UTC 2020

Please review the proposed fix [1] of the issue [2]. This replaces the “loopy” XBuffer.put(XBuffer src) fallback code
     while (src.hasRemaining())
with an implementation which behaves as if the source elements were first copied to a temporary array before being written into the target. The test fails before and passes after the implementation change is applied.

I am aware of the flagged and commented out sections in the test.



[1] http://cr.openjdk.java.net/~bpb/8245121/webrev.00/
[2] https://bugs.openjdk.java.net/browse/JDK-8245121

More information about the nio-dev mailing list