Check if libnativehelper is loaded in the process and if it has these awful wrappers for JNI_CreateJavaVM and JNI_GetCreatedJavaVMs that crash the app if you don't create a JniInvocation instance first. If it isn't we just fail here and don't initialize anything. See this code for reference: https://android.googlesource.com/platform/libnativehelper/+/master/JniInvocation.cpp