提交 447bc971 编写于 作者: K kamg

6975210: java.lang.VerifyError in some of JCK tests

Summary: Naked oop in verificationType::is_reference_assignable_from()
Reviewed-by: never, kvn, coleenp
上级 569135bf
......@@ -54,10 +54,12 @@ bool VerificationType::is_reference_assignable_from(
// any object or array is assignable to java.lang.Object
return true;
}
klassOop this_class = SystemDictionary::resolve_or_fail(
klassOop obj = SystemDictionary::resolve_or_fail(
name_handle(), Handle(THREAD, context->class_loader()),
Handle(THREAD, context->protection_domain()), true, CHECK_false);
if (this_class->klass_part()->is_interface()) {
KlassHandle this_class(THREAD, obj);
if (this_class->is_interface()) {
// We treat interfaces as java.lang.Object, including
// java.lang.Cloneable and java.io.Serializable
return true;
......@@ -65,7 +67,7 @@ bool VerificationType::is_reference_assignable_from(
klassOop from_class = SystemDictionary::resolve_or_fail(
from.name_handle(), Handle(THREAD, context->class_loader()),
Handle(THREAD, context->protection_domain()), true, CHECK_false);
return instanceKlass::cast(from_class)->is_subclass_of(this_class);
return instanceKlass::cast(from_class)->is_subclass_of(this_class());
}
} else if (is_array() && from.is_array()) {
VerificationType comp_this = get_component(CHECK_false);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册