upstream JNIEnv changes from tgs-android