mirror of
https://github.com/openjdk/jdk.git
synced 2025-08-27 23:04:50 +02:00
Merge
This commit is contained in:
commit
f3576a18a9
17 changed files with 102 additions and 136 deletions
|
@ -1582,8 +1582,11 @@ JVM_ENTRY(jbyteArray, JVM_GetClassTypeAnnotations(JNIEnv *env, jclass cls))
|
|||
if (!java_lang_Class::is_primitive(JNIHandles::resolve(cls))) {
|
||||
Klass* k = java_lang_Class::as_Klass(JNIHandles::resolve(cls));
|
||||
if (k->oop_is_instance()) {
|
||||
typeArrayOop a = Annotations::make_java_array(InstanceKlass::cast(k)->type_annotations()->class_annotations(), CHECK_NULL);
|
||||
return (jbyteArray) JNIHandles::make_local(env, a);
|
||||
Annotations* type_annotations = InstanceKlass::cast(k)->type_annotations();
|
||||
if (type_annotations != NULL) {
|
||||
typeArrayOop a = Annotations::make_java_array(type_annotations->class_annotations(), CHECK_NULL);
|
||||
return (jbyteArray) JNIHandles::make_local(env, a);
|
||||
}
|
||||
}
|
||||
}
|
||||
return NULL;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue