Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8358815

Exception event spec has stale reference to catch_klass parameter

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P4 P4
    • 26
    • 26
    • hotspot
    • None
    • b02

      The JVMTI Exception event callback has the following signature:
      void JNICALL
      Exception(jvmtiEnv *jvmti_env,
                  JNIEnv* jni_env,
                  jthread thread,
                  jmethodID method,
                  jlocation location,
                  jobject exception,
                  jmethodID catch_method,
                  jlocation catch_location)

      The event spec has these two sentences:
       "If there are native methods on the call stack between the throw location and the catch clause, the exception may be reset by one of those native methods. Similarly, exceptions that are reported as uncaught (catch_klass et al. set to 0) may in fact be caught by native code."

      Obviously, there is no such `catch_klass` parameter but there are `catch_method` and `catch_location` instead.

      See: https://docs.oracle.com/en/java/javase/24/docs/specs/jvmti.html#Exception

            sspitsyn Serguei Spitsyn
            sspitsyn Serguei Spitsyn
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: