mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-12 04:45:45 +00:00
Backed out changeset 8d59556d361f (bug 1281341) for dt8 crashes
This commit is contained in:
parent
395241c288
commit
73a127f3e1
@ -102,10 +102,6 @@ registerCleanupFunction(function* cleanup() {
|
||||
while (gBrowser.tabs.length > 1) {
|
||||
yield closeTabAndToolbox(gBrowser.selectedTab);
|
||||
}
|
||||
|
||||
// Force GC and CC to get rid of disconnected docshells and windows (see Bug 1281341).
|
||||
Cu.forceGC();
|
||||
Cu.forceCC();
|
||||
});
|
||||
|
||||
/**
|
||||
|
@ -2163,6 +2163,14 @@ Toolbox.prototype = {
|
||||
// to destroyed listeners to still query toolbox attributes
|
||||
this._host = null;
|
||||
this._toolPanels.clear();
|
||||
|
||||
// Force GC to prevent long GC pauses when running tests and to free up
|
||||
// memory in general when the toolbox is closed.
|
||||
if (flags.testing) {
|
||||
win.QueryInterface(Ci.nsIInterfaceRequestor)
|
||||
.getInterface(Ci.nsIDOMWindowUtils)
|
||||
.garbageCollect();
|
||||
}
|
||||
}).then(null, console.error);
|
||||
|
||||
let leakCheckObserver = ({wrappedJSObject: barrier}) => {
|
||||
|
Loading…
Reference in New Issue
Block a user