Add class to verifier's rejected list if superclass is erroneous.
This will prevent the compiler from trying to compile one of these
classes, which will fail because it has no GC map.
Bug: 12104117
Change-Id: I77ec77d30ee5dc92d7f4c594f1e8f1ce9b67855d
diff --git a/runtime/class_linker.cc b/runtime/class_linker.cc
index a98673d..643c183 100644
--- a/runtime/class_linker.cc
+++ b/runtime/class_linker.cc
@@ -2489,6 +2489,8 @@
if (cause.get() != nullptr) {
self->GetException(nullptr)->SetCause(cause.get());
}
+ ClassReference ref(klass->GetDexCache()->GetDexFile(), klass->GetDexClassDefIndex());
+ verifier::MethodVerifier::AddRejectedClass(ref);
klass->SetStatus(mirror::Class::kStatusError, self);
return;
}