Debug agent should print stack trace when exiting due to an exception

XMLWordPrintable

    • Type: Enhancement
    • Resolution: Duplicate
    • Priority: P4
    • None
    • Affects Version/s: 24
    • Component/s: core-svc
    • None

      The following is a somewhat common pattern in the debug agent:

          if (JNI_FUNC_PTR(env,ExceptionCheck)(env)) {
              JNI_FUNC_PTR(env,ExceptionClear)(env); // keep -Xcheck:jni happy
              ERROR_MESSAGE(("JNI Exception occurred calling Module.getName()"));
              EXIT_ERROR(AGENT_ERROR_JNI_EXCEPTION, NULL);
          }

      It would be useful to print the exception when this code is executed and also create a utility function or macro to handle all of this. Something like EXIT_ERROR_ON_EXCEPTION.

            Assignee:
            Chris Plummer
            Reporter:
            Chris Plummer
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved: