mirror of
https://github.com/corda/corda.git
synced 2025-01-19 11:16:54 +00:00
if we can't resolve a bootstrap class in isAssignableFrom(), we swallow the exception and return false
This commit is contained in:
parent
fe0708c09a
commit
f1bc2be9f9
@ -1082,9 +1082,8 @@ interpret(Thread* t)
|
||||
(t, className(t, objectClass(t, peekObject(t, sp - 1))), 0),
|
||||
&byteArrayBody(t, className(t, class_), 0));
|
||||
exception = makeClassCastException(t, message);
|
||||
goto throw_;
|
||||
}
|
||||
|
||||
if (UNLIKELY(exception)) goto throw_;
|
||||
}
|
||||
} goto loop;
|
||||
|
||||
@ -1785,8 +1784,6 @@ interpret(Thread* t)
|
||||
} else {
|
||||
pushInt(t, 0);
|
||||
}
|
||||
|
||||
if (UNLIKELY(exception)) goto throw_;
|
||||
} else {
|
||||
popObject(t);
|
||||
pushInt(t, 0);
|
||||
|
@ -2132,7 +2132,10 @@ isAssignableFrom(Thread* t, object a, object b)
|
||||
if (classFlags(t, a) & ACC_INTERFACE) {
|
||||
if (classVmFlags(t, b) & BootstrapFlag) {
|
||||
resolveClass(t, className(t, b));
|
||||
if (UNLIKELY(t->exception)) return false;
|
||||
if (UNLIKELY(t->exception)) {
|
||||
t->exception = 0;
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
for (; b; b = classSuper(t, b)) {
|
||||
|
@ -1309,6 +1309,10 @@ parseJavaClass(Object* type, Stream* s, Object* declarations)
|
||||
|
||||
unsigned interfaceCount = s->read2();
|
||||
s->skip(interfaceCount * 2);
|
||||
// for (unsigned i = 0; i < interfaceCount; ++i) {
|
||||
// const char* name = reinterpret_cast<const char*>
|
||||
// (pool[pool[s->read2() - 1] - 1]);
|
||||
// }
|
||||
|
||||
unsigned fieldCount = s->read2();
|
||||
for (unsigned i = 0; i < fieldCount; ++i) {
|
||||
|
Loading…
Reference in New Issue
Block a user