8020489: VM crash when non-existent interface called by invokespecial
Reviewed-by: kamg, coleenp
This commit is contained in:
parent
fefcbb92f2
commit
c0f4055c78
@ -870,7 +870,6 @@ class ErasedShadowChecker : public ShadowChecker {
|
||||
: ShadowChecker(thread, name, holder, target) {}
|
||||
};
|
||||
|
||||
|
||||
// Find the unique qualified candidate from the perspective of the super_class
|
||||
// which is the resolved_klass, which must be an immediate superinterface
|
||||
// of klass
|
||||
@ -884,7 +883,6 @@ Method* find_erased_super_default(InstanceKlass* current_class, InstanceKlass* s
|
||||
|
||||
if (family != NULL) {
|
||||
family->determine_target(current_class, CHECK_NULL); // get target from current_class
|
||||
}
|
||||
|
||||
if (family->has_target()) {
|
||||
Method* target = family->get_selected_target();
|
||||
@ -919,8 +917,14 @@ Method* find_erased_super_default(InstanceKlass* current_class, InstanceKlass* s
|
||||
THROW_MSG_(vmSymbols::java_lang_AbstractMethodError(),
|
||||
family->get_exception_message()->as_C_string(), NULL);
|
||||
}
|
||||
} else {
|
||||
// no method found
|
||||
ResourceMark rm(THREAD);
|
||||
THROW_MSG_(vmSymbols::java_lang_NoSuchMethodError(),
|
||||
Method::name_and_sig_as_C_string(current_class,
|
||||
method_name, sig), NULL);
|
||||
}
|
||||
}
|
||||
|
||||
// This is called during linktime when we find an invokespecial call that
|
||||
// refers to a direct superinterface. It indicates that we should find the
|
||||
// default method in the hierarchy of that superinterface, and if that method
|
||||
|
Loading…
x
Reference in New Issue
Block a user