зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1447073 - Check that helper threads never allocate in the nursery r=sfink
This commit is contained in:
Родитель
073e868441
Коммит
6d800ba596
|
@ -82,10 +82,12 @@ template <AllowGC allowGC>
|
|||
JSObject*
|
||||
GCRuntime::tryNewNurseryObject(JSContext* cx, size_t thingSize, size_t nDynamicSlots, const Class* clasp)
|
||||
{
|
||||
MOZ_RELEASE_ASSERT(!cx->helperThread());
|
||||
|
||||
MOZ_ASSERT(cx->isNurseryAllocAllowed());
|
||||
MOZ_ASSERT(!cx->helperThread());
|
||||
MOZ_ASSERT(!cx->isNurseryAllocSuppressed());
|
||||
MOZ_ASSERT(!IsAtomsCompartment(cx->compartment()));
|
||||
|
||||
JSObject* obj = cx->nursery().allocateObject(cx, thingSize, nDynamicSlots, clasp);
|
||||
if (obj)
|
||||
return obj;
|
||||
|
|
Загрузка…
Ссылка в новой задаче