RFR: 8195690: JNI GetObjectRefType doesn't handle NULL

Kim Barrett kim.barrett at oracle.com
Mon Jan 22 22:24:50 UTC 2018


Please review this fix of GetObjectRefType when applied to a NULL
handle argument.  It should return JNIInvalidRefType, but was instead
asserting in debug builds, and maybe worse things in release builds.

In addition to making GetObjectRefType handle NULL properly, various
functions in JNIHandles and OopStorage now have non-NULL handle argument
preconditions and corresponding assertions.

CR:
https://bugs.openjdk.java.net/browse/JDK-8195690

Webrev:
http://cr.openjdk.java.net/~kbarrett/8195690/open.00/

Testing:
Mach5 {hs,jdk}-tier{1,2,3}
Locally ran JCK vm/jni tests
Locally ran tonga vm.runtime tests for jni tests



More information about the hotspot-runtime-dev mailing list