mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-20 16:55:40 +00:00
Bug 1280591 - Check if gray roots are valid when we add them. r=terrence
This commit is contained in:
parent
84787f181a
commit
d294fad895
@ -414,6 +414,9 @@ void
|
||||
BufferGrayRootsTracer::onChild(const JS::GCCellPtr& thing)
|
||||
{
|
||||
MOZ_ASSERT(runtime()->isHeapBusy());
|
||||
MOZ_RELEASE_ASSERT(thing);
|
||||
// Check if |thing| is corrupt by calling a method that touches the heap.
|
||||
MOZ_RELEASE_ASSERT(thing.asCell()->getTraceKind() <= JS::TraceKind::Null);
|
||||
|
||||
if (bufferingGrayRootsFailed)
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user