mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-22 03:54:33 +02:00
8076290: JCK test api/xsl/conf/string/string17 starts failing after JDK-8074297
Reviewed-by: joehw
This commit is contained in:
parent
d4502a832f
commit
75f2048a84
1 changed files with 4 additions and 2 deletions
|
@ -298,7 +298,7 @@ public final class BasisLibrary {
|
|||
return(EMPTYSTRING);
|
||||
|
||||
int istart = (int)Math.round(start) - 1;
|
||||
final int ilength = (int)Math.round(length);
|
||||
int ilength = (int)Math.round(length);
|
||||
final int isum;
|
||||
if (Double.isInfinite(length))
|
||||
isum = Integer.MAX_VALUE;
|
||||
|
@ -309,8 +309,10 @@ public final class BasisLibrary {
|
|||
if (isum < 0 || istart > strlen)
|
||||
return(EMPTYSTRING);
|
||||
|
||||
if (istart < 0)
|
||||
if (istart < 0) {
|
||||
ilength += istart;
|
||||
istart = 0;
|
||||
}
|
||||
|
||||
try {
|
||||
istart = value.offsetByCodePoints(0, istart);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue