diff src/share/vm/classfile/systemDictionary.cpp @ 3785:ddd894528dbc

7056328: JSR 292 invocation sometimes fails in adapters for types not on boot class path Reviewed-by: never
author jrose
date Thu, 23 Jun 2011 17:14:06 -0700
parents 167b70ff3abc
children be4ca325525a fdb992d83a87
line wrap: on
line diff
--- a/src/share/vm/classfile/systemDictionary.cpp	Wed Jun 22 14:45:37 2011 -0700
+++ b/src/share/vm/classfile/systemDictionary.cpp	Thu Jun 23 17:14:06 2011 -0700
@@ -2367,6 +2367,8 @@
         // Link m to his method type, if it is suitably generic.
         oop mtform = java_lang_invoke_MethodType::form(mt());
         if (mtform != NULL && mt() == java_lang_invoke_MethodTypeForm::erasedType(mtform)
+            // vmlayout must be an invokeExact:
+            && name_id == vmSymbols::VM_SYMBOL_ENUM_NAME(invokeExact_name)
             && java_lang_invoke_MethodTypeForm::vmlayout_offset_in_bytes() > 0) {
           java_lang_invoke_MethodTypeForm::init_vmlayout(mtform, m());
         }