From http://java.sun.com/j2se/1.4/docs/guide/jni/spec/design.doc.html#17629 :
Asynchronous Exceptions
In cases of multiple threads, threads other than the current thread may
post an asynchronous exception. An asynchronous exception does not
immediately affect the execution of the native code in the current
thread, until:
* the native code calls one of the JNI functions that could raise
synchronous exceptions, or
* the native code uses ExceptionOccurred() to explicitly check for
synchronous and asynchronous exceptions.
Note that only those JNI function that could potentially raise
synchronous exceptions check for asynchronous exceptions.
----------------------------------------------------------------------
Bug: None of the JNI methods check for asynchronous exceptions
before executing their own particular function.
- relates to
-
JDK-4808145 Regression: -Xcheck:jni code flags correct code as failing
- Closed