Relates :
|
|
Relates :
|
JDK-8043224 introduced a thread flag for warning the user when -Xcheck:jni should complain about native code not clearing or checking exceptions. Said flag should be implicitly cleared when returning to Java frame. That is, native code which makes a call normally requiring an exception check (e.g. calling Java method), does not need to check for exceptions if said code calls no other JNI API. Returning to Java frame should clear the pending check flag (for -Xcheck:jni warnings) and allow the exception to propagate to Java code as per normal. Without this fix, there are quite a number of false warnings produced by core-library native code, causing some noise during JVM testing and when users need -Xcheck:jni