Incorporate additional feedback to native JNI checks
Bug: 124338141
Test: m art_libartbase_tests_memory_type_table_test && \
out/host/linux-x86/nativetest/art_libartbase_tests/memory_type_table_test
Test: m && flashall && boot
(cherry picked from commit fbbda47e032d5cf0db33d2ce671bd37def1058fd)
Change-Id: I26f0a06cf36c2591f4dc30fc6dc3ed443bd8e4a4
Merged-In: I26f0a06cf36c2591f4dc30fc6dc3ed443bd8e4a4
diff --git a/runtime/runtime.cc b/runtime/runtime.cc
index bc6b9b7..8133193 100644
--- a/runtime/runtime.cc
+++ b/runtime/runtime.cc
@@ -492,6 +492,8 @@
// instance. We rely on a small initialization order issue in Runtime::Start() that requires
// elements of WellKnownClasses to be null, see b/65500943.
WellKnownClasses::Clear();
+
+ JniShutdownNativeCallerCheck();
}
struct AbortState {
@@ -1826,7 +1828,7 @@
// Having loaded native libraries for Managed Core library, enable field and
// method resolution checks via JNI from native code.
- JNIInitializeNativeCallerCheck();
+ JniInitializeNativeCallerCheck();
VLOG(startup) << "Runtime::InitNativeMethods exiting";
}