Bug 1313897 - Suppress assertion about non-empty UnboxedLayout list if GC cells were leaked at shutdown r=sfink

This commit is contained in:
Jon Coppeard 2017-01-27 10:21:58 +00:00
Родитель dca07ffc3a
Коммит 87e23bd975
1 изменённых файлов: 7 добавлений и 0 удалений

Просмотреть файл

@ -117,6 +117,13 @@ JSCompartment::~JSCompartment()
js_delete(nonSyntacticLexicalEnvironments_),
js_free(enumerators);
#ifdef DEBUG
// Avoid assertion destroying the unboxed layouts list if the embedding
// leaked GC things.
if (!rt->gc.shutdownCollectedEverything())
unboxedLayouts.clear();
#endif
runtime_->numCompartments--;
}