mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-04-01 20:13:00 +00:00
Bug 889986 - Assert nursery allocations are large enough to be replaced with a RelocationOverlay r=terrence
This commit is contained in:
parent
fbe3cbaee3
commit
776c4471d9
@ -97,6 +97,9 @@ js::Nursery::allocate(size_t size)
|
||||
{
|
||||
JS_ASSERT(!runtime()->isHeapBusy());
|
||||
|
||||
/* Ensure there's enough space to replace the contents with a RelocationOverlay. */
|
||||
JS_ASSERT(size >= sizeof(RelocationOverlay));
|
||||
|
||||
if (position() + size > currentEnd()) {
|
||||
if (currentChunk_ + 1 == numActiveChunks_)
|
||||
return nullptr;
|
||||
|
Loading…
x
Reference in New Issue
Block a user