Bug 341499: The assert in js_NewGCThing about not running GC now takes into account that we allow allocation from close hooks. r=mrbkap

This commit is contained in:
igor.bukanov%gmail.com 2006-06-15 10:42:57 +00:00
Родитель e43c76eb9d
Коммит 5c77935888
1 изменённых файлов: 2 добавлений и 2 удалений

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

@ -820,8 +820,8 @@ js_NewGCThing(JSContext *cx, uintN flags, size_t nbytes)
rt->gcMallocBytes += localMallocBytes;
}
#endif
JS_ASSERT(!rt->gcRunning);
if (rt->gcRunning) {
JS_ASSERT(!rt->gcRunning || rt->gcClosePhase);
if (rt->gcRunning && !rt->gcClosePhase) {
METER(rt->gcStats.finalfail++);
JS_UNLOCK_GC(rt);
return NULL;