Partially ObjPtr<>-ify Object, fix stale ref in test.

Test: m test-art-host-gtest
Test: testrunner.py --host --optimizing
Bug: 31113334
Change-Id: I0c0bc669c0ab8d99185e662a2fec16f32a42a0a2
diff --git a/runtime/jni/check_jni.cc b/runtime/jni/check_jni.cc
index 7279299..4a8453a 100644
--- a/runtime/jni/check_jni.cc
+++ b/runtime/jni/check_jni.cc
@@ -359,7 +359,7 @@
     if (f == nullptr) {
       return false;
     }
-    mirror::Class* c = o->GetClass();
+    ObjPtr<mirror::Class> c = o->GetClass();
     if (c->FindInstanceField(f->GetName(), f->GetTypeDescriptor()) == nullptr) {
       AbortF("jfieldID %s not valid for an object of class %s",
              f->PrettyField().c_str(), o->PrettyTypeOf().c_str());