mirror of
https://github.com/corda/corda.git
synced 2025-01-09 06:23:04 +00:00
backport GC safety fixes from gnu branch
This commit is contained in:
parent
47ab980550
commit
afdab27e02
@ -5984,9 +5984,11 @@ class MyProcessor: public Processor {
|
|||||||
virtual void
|
virtual void
|
||||||
initVtable(Thread* t, object c)
|
initVtable(Thread* t, object c)
|
||||||
{
|
{
|
||||||
|
PROTECT(t, c);
|
||||||
for (int i = classLength(t, c) - 1; i >= 0; --i) {
|
for (int i = classLength(t, c) - 1; i >= 0; --i) {
|
||||||
classVtable(t, c, i) = reinterpret_cast<void*>
|
void* thunk = reinterpret_cast<void*>
|
||||||
(virtualThunk(static_cast<MyThread*>(t), i));
|
(virtualThunk(static_cast<MyThread*>(t), i));
|
||||||
|
classVtable(t, c, i) = thunk;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2439,6 +2439,8 @@ parseClass(Thread* t, const uint8_t* data, unsigned size)
|
|||||||
classLoader(t, class_),
|
classLoader(t, class_),
|
||||||
vtableLength);
|
vtableLength);
|
||||||
|
|
||||||
|
PROTECT(t, real);
|
||||||
|
|
||||||
t->m->processor->initVtable(t, real);
|
t->m->processor->initVtable(t, real);
|
||||||
|
|
||||||
updateClassTables(t, real, class_);
|
updateClassTables(t, real, class_);
|
||||||
|
Loading…
Reference in New Issue
Block a user