-
Type:
Enhancement
-
Resolution: Not an Issue
-
Priority:
P4
-
Affects Version/s: 16
-
Component/s: hotspot
here's Signature code that unconditionally reads _body[0], which would assert (but class loading checks for invalid signatures that prevents this from happening)
BasicType Signature::basic_type(const Symbol* signature) {
return basic_type(signature->char_at(0));
}
char Symbol::char_at(int index) const {
assert(index >=0 && index < length(), "symbol index overflow");
return (char)base()[index];
}
Signature::basic_type() should be fixed to either check for length, and/or assert that signature is a valid signature.
BasicType Signature::basic_type(const Symbol* signature) {
return basic_type(signature->char_at(0));
}
char Symbol::char_at(int index) const {
assert(index >=0 && index < length(), "symbol index overflow");
return (char)base()[index];
}
Signature::basic_type() should be fixed to either check for length, and/or assert that signature is a valid signature.