Merge "Strengthen annotation-related checks in JNI code."