mirror of
https://github.com/corda/corda.git
synced 2025-01-04 04:04:27 +00:00
Handle null pointer in PopLocalFrame
This commit is contained in:
parent
887a32bc10
commit
cad4719f7d
@ -3370,12 +3370,21 @@ PushLocalFrame(Thread* t, jint capacity)
|
|||||||
uint64_t
|
uint64_t
|
||||||
popLocalFrame(Thread* t, uintptr_t* arguments)
|
popLocalFrame(Thread* t, uintptr_t* arguments)
|
||||||
{
|
{
|
||||||
object result = *reinterpret_cast<jobject>(arguments[0]);
|
uint64_t r;
|
||||||
PROTECT(t, result);
|
jobject presult = reinterpret_cast<jobject>(arguments[0]);
|
||||||
|
if(presult != NULL) {
|
||||||
|
object result = *presult;
|
||||||
|
PROTECT(t, result);
|
||||||
|
|
||||||
t->m->processor->popLocalFrame(t);
|
t->m->processor->popLocalFrame(t);
|
||||||
|
|
||||||
return reinterpret_cast<uint64_t>(makeLocalReference(t, result));
|
r = reinterpret_cast<uint64_t>(makeLocalReference(t, result));
|
||||||
|
} else {
|
||||||
|
t->m->processor->popLocalFrame(t);
|
||||||
|
r = 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
return r;
|
||||||
}
|
}
|
||||||
|
|
||||||
jobject JNICALL
|
jobject JNICALL
|
||||||
|
Loading…
Reference in New Issue
Block a user