Hi All
I'm passing an array from C to Java. (check pseudo in following code snippet)
JNI_METHOD(jenv, jobj, jlong arraySize, jobjectArray jArry)
{
arraySize = 10
jArry = jenv->NewObjectArray
}
Won't calling this method cause a memory leak since there is no place where we could release/delete the created object array .
Is it really so? any comments , guidence
TIA
PS: I suppose that even jlong (primitive type) parameters are pssed by reference (in JNI calls) so if I change value of some jlong in C, it will be reflected in calling java code. A little testing would reveal the fact. But can some body tell me the role/logic which governs the behavior?
Asim Hussnain , IPA