Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
02110-1301, USA.
- $Id: jvm.c 8295 2007-08-11 17:57:24Z michi $
+ $Id: jvm.c 8305 2007-08-15 13:49:26Z panzi $
*/
#include "mm/memory.h"
#include "native/jni.h"
+#include "native/llni.h"
#include "native/native.h"
#include "native/include/java_lang_AssertionStatusDirectives.h"
jbyteArray JVM_GetFieldAnnotations(JNIEnv *env, jobject field)
{
java_lang_reflect_Field *rf = (java_lang_reflect_Field*)field;
+ java_bytearray *ba = NULL;
TRACEJVMCALLS("JVM_GetFieldAnnotations: field=%p", field);
return NULL;
}
- return (jbyteArray)rf->annotations;
+ LLNI_field_get_ref(rf, annotations, ba);
+
+ return (jbyteArray)ba;
}
jbyteArray JVM_GetMethodAnnotations(JNIEnv *env, jobject method)
{
java_lang_reflect_Method *rm = (java_lang_reflect_Method*)method;
+ java_bytearray *ba = NULL;
TRACEJVMCALLS("JVM_GetMethodAnnotations: method=%p", method);
return NULL;
}
- return (jbyteArray)rm->annotations;
+ LLNI_field_get_ref(rm, annotations, ba);
+
+ return (jbyteArray)ba;
}
jbyteArray JVM_GetMethodDefaultAnnotationValue(JNIEnv *env, jobject method)
{
java_lang_reflect_Method *rm = (java_lang_reflect_Method*)method;
+ java_bytearray *ba = NULL;
TRACEJVMCALLS("JVM_GetMethodDefaultAnnotationValue: method=%p", method);
return NULL;
}
- return (jbyteArray)rm->annotationDefault;
+ LLNI_field_get_ref(rm, annotationDefault, ba);
+
+ return (jbyteArray)ba;
}
jbyteArray JVM_GetMethodParameterAnnotations(JNIEnv *env, jobject method)
{
java_lang_reflect_Method *rm = (java_lang_reflect_Method*)method;
+ java_bytearray *ba = NULL;
TRACEJVMCALLS("JVM_GetMethodParameterAnnotations: method=%p", method);
return NULL;
}
- return (jbyteArray)rm->parameterAnnotations;
+ LLNI_field_get_ref(rm, parameterAnnotations, ba);
+
+ return (jbyteArray)ba;
}
jobject JVM_GetClassConstantPool(JNIEnv *env, jclass cls)
{
#if defined(ENABLE_ANNOTATIONS)
- sun_reflect_ConstantPool *constantPool = NULL;
+ sun_reflect_ConstantPool *constantPool = NULL;
+ java_lang_Object *constantPoolOop = (java_lang_Object*)cls;
TRACEJVMCALLS("JVM_GetClassConstantPool: cls=%p", cls);
return NULL;
}
- constantPool->constantPoolOop = (java_lang_Object*)cls;
+ LLNI_field_set_ref(constantPool, constantPoolOop, constantPoolOop);
+
return (jobject)constantPool;
#else
log_println("JVM_GetClassConstantPool: cls=%p, not implemented in this configuration!", cls);
return NULL;
}
- if (!resolve_classref(NULL,ref,resolveLazy,true,true,&c)) {
+ if (!resolve_classref(NULL, ref, resolveLazy, true, true, &c)) {
return NULL;
}
return NULL;
}
- if (!resolve_classref(NULL,ref->p.classref,resolveLazy,true,true,&c)) {
+ if (!resolve_classref(NULL, ref->p.classref, resolveLazy, true, true, &c)) {
return NULL;
}
return NULL;
}
- if (!resolve_classref(NULL,ref->p.classref,resolveLazy,true,true,&c)) {
+ if (!resolve_classref(NULL, ref->p.classref, resolveLazy, true, true, &c)) {
return NULL;
}