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

Native exception/signal handler might overwrite JVM's

XMLWordPrintable

      JavaCalls::call goes through os::os_exception_wrapper which, on Windows x86_32/x64 wraps the call in a __try/__catch block.

      This seems to be needed in the case where a native code installs it's own structured exception handler that would try to handle EXCEPTION_ACCESS_VIOLATION, which would interfere with the JVM's implicit NullPointerExceptions.

      We need to do something similar for Panama upcalls, it seems.

      (Though, I'll note that the same thing can occur on other platforms, e.g. Linux, where native code can install its own signal handler that indiscriminately tries to handle all SEGV signals)

            jvernee Jorn Vernee
            jvernee Jorn Vernee
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: