realm-java icon indicating copy to clipboard operation
realm-java copied to clipboard

Check if local/global references are properly released in JNI

Open stk1m1 opened this issue 10 years ago • 1 comments

Goal

What do you want to achieve?

We should check if local/global references in JNI has been properly released. If not, we should do so as @kneth has spotted, and @beeender has mentioned

Expected Results

This will prevent us from having stack overflow, and could reduce memory pressure if there ever is.

Actual Results

N/A

Steps & Code to Reproduce

N/A

Code Sample

env->DeleteLocalRef(javaArray);

Version of Realm and tooling

Realm version(s): 1.x Android Studio version: N/A Which Android version and device: N/A

stk1m1 avatar Jun 16 '16 08:06 stk1m1

We introduced JavaGlobalRef in JNI, this should be handled well now.

beeender avatar Dec 11 '17 07:12 beeender