8257511: JDK-8254082 brings regression to AbstractStringBuilder.insert(int dstOffset, CharSequence s, int start, int end)

Reviewed-by: alanb, rriggs, bpb
This commit is contained in:
Claes Redestad 2020-12-01 22:50:05 +00:00
parent 015e6e58c5
commit 00e79db89e
2 changed files with 25 additions and 9 deletions

View file

@ -1717,7 +1717,7 @@ abstract class AbstractStringBuilder implements Appendable, CharSequence {
if (getCoder() != str.coder()) {
inflate();
}
str.getBytes(value, off, index, coder, end);
str.getBytes(value, off, index, coder, end - off);
}
private void putStringAt(int index, String str) {