Don't try to recompile scripts when clearing traps during GC, bug 683966.

This commit is contained in:
Brian Hackett 2011-09-04 13:33:33 -07:00
Родитель b11768c8fc
Коммит 0d2e4d3db2
1 изменённых файлов: 4 добавлений и 1 удалений

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

@ -225,7 +225,10 @@ BreakpointSite::clearTrap(JSContext *cx, BreakpointSiteMap::Enum *e,
trapClosure.setUndefined();
if (enabledCount == 0) {
*pc = realOpcode;
recompile(cx, true); /* ignore failure */
if (!cx->runtime->gcRunning) {
/* If the GC is running then the script is being destroyed. */
recompile(cx, true); /* ignore failure */
}
destroyIfEmpty(cx->runtime, e);
}
}