Hi all, If the direct handshake is executed by the target thread, the JNI local(s) are created in that thread but returned in the handshaking thread. They thus are not safe to use. (thread might even have exited by this point)
Code: http://cr.openjdk.java.net/~rehn/8247248/v1/webrev/ Unfortunately there is no way the distinguish a local jobject vs a global. Which makes it hard to track when the jobject is global and not. Issue: https://bugs.openjdk.java.net/browse/JDK-8247248 Local testing of JDI/JVMTI and t1-5. (no real crash so there is nothing to reproduce) Thanks, Robbin