8197780: Null pointer dereference in Klass::is_instance_klass of klass.hpp:532

Make generate_class_cast_message able to deal with NULL klass from the constant pool.

Reviewed-by: hseigel, lfoltan
This commit is contained in:
Coleen Phillimore 2018-02-23 07:47:29 -05:00
parent 2fb89326ba
commit 809315bdd1
6 changed files with 100 additions and 95 deletions

View file

@ -318,7 +318,7 @@ class SharedRuntime: AllStatic {
// The caller (or one of it's callers) must use a ResourceMark
// in order to correctly free the result.
//
static char* generate_class_cast_message(Klass* caster_klass, Klass* target_klass);
static char* generate_class_cast_message(Klass* caster_klass, Klass* target_klass, Symbol* target_klass_name = NULL);
// Resolves a call site- may patch in the destination of the call into the
// compiled code.