mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 23:04:50 +02:00
8193444: SimpleDateFormat throws ArrayIndexOutOfBoundsException when format contains long sequences of unicode characters
Reviewed-by: naoto, rriggs
This commit is contained in:
parent
a2a00af3c3
commit
0cb3d46cd7
2 changed files with 85 additions and 1 deletions
|
@ -831,7 +831,7 @@ public class SimpleDateFormat extends DateFormat {
|
|||
break;
|
||||
}
|
||||
}
|
||||
compiledCode.append((char)(TAG_QUOTE_CHARS << 8 | (j - i)));
|
||||
encode(TAG_QUOTE_CHARS, j - i, compiledCode);
|
||||
for (; i < j; i++) {
|
||||
compiledCode.append(pattern.charAt(i));
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue