Bug 752468: Remove some code accidentally reintroduced in Bug 751999. r=jst
authorKyle Huey <khuey@kylehuey.com>
Mon, 04 Jun 2012 20:39:21 -0700
changeset 100566 a7a905fd70d5da436e4727194d568dffaaaaac9c
parent 100565 3edf11eed1199f4dad191d4b08889c0a4bb8dbee
child 100622 c76497029f0d6c9c33a2cd6712a7cebebed56690
push idunknown
push userunknown
push dateunknown
reviewersjst
bugs752468, 751999
milestone16.0a1
Bug 752468: Remove some code accidentally reintroduced in Bug 751999. r=jst
dom/base/nsGlobalWindow.cpp
--- a/dom/base/nsGlobalWindow.cpp
+++ b/dom/base/nsGlobalWindow.cpp
@@ -2217,26 +2217,16 @@ nsGlobalWindow::DetachFromDocShell()
   // Make sure that this is called before we null out the document.
   NotifyDOMWindowDestroyed(this);
 
   NotifyWindowIDDestroyed("outer-window-destroyed");
 
   nsGlobalWindow *currentInner = GetCurrentInnerWindowInternal();
 
   if (currentInner) {
-    JSObject* obj = currentInner->FastGetGlobalJSObject();
-    if (obj) {
-      JSContext* cx = nsContentUtils::ThreadJSContextStack()->GetSafeJSContext();
-
-      JSAutoRequest ar(cx);
-
-      js::NukeChromeCrossCompartmentWrappersForGlobal(cx, obj,
-                                                      js::NukeForGlobalObject);
-    }
-
     NS_ASSERTION(mDoc, "Must have doc!");
     
     // Remember the document's principal.
     mDocumentPrincipal = mDoc->NodePrincipal();
 
     // Release our document reference
     mDocument = nsnull;
     mDoc = nsnull;