8367619: String.format in outOfRangeException uses wrong format specifier for String argument

Reviewed-by: fandreuzzi, rriggs, liach
This commit is contained in:
Guanqiang Han 2025-09-16 14:57:42 +00:00 committed by Chen Liang
parent c82070e635
commit 58007c0bcc

View File

@ -230,7 +230,7 @@ public final class Util {
public static IllegalArgumentException outOfRangeException(int value, String fieldName, String typeName) {
return new IllegalArgumentException(
String.format("%s out of range of %d: %d", fieldName, typeName, value));
String.format("%s out of range of %s: %d", fieldName, typeName, value));
}
/// Ensures the given mask won't be truncated when written as an access flag