Backed out changeset 7fa2f2eff658 (bug 806127)
authorJustin Lebar <justin.lebar@gmail.com>
Tue, 30 Oct 2012 21:35:47 -0400
changeset 111980 1e04d8f5e601baded077ef0ae967c691b1836d65
parent 111979 df6cbf360b2506a2d7f11d5e0350e1948a3c5788
child 111981 9c357f7836b4115fce80bb9e55c75a54dfff2af4
push id93
push usernmatsakis@mozilla.com
push dateWed, 31 Oct 2012 21:26:57 +0000
bugs806127
milestone19.0a1
backs out7fa2f2eff658e41e55b3c6a35231afbfad571b7d
Backed out changeset 7fa2f2eff658 (bug 806127)
content/base/src/ThirdPartyUtil.cpp
--- a/content/base/src/ThirdPartyUtil.cpp
+++ b/content/base/src/ThirdPartyUtil.cpp
@@ -110,19 +110,17 @@ ThirdPartyUtil::IsThirdPartyWindow(nsIDO
       *aResult = true;
       return NS_OK;
     }
   }
 
   nsCOMPtr<nsIDOMWindow> current = aWindow, parent;
   nsCOMPtr<nsIURI> parentURI;
   do {
-    // We use GetScriptableParent rather than GetParent because we consider
-    // <iframe mozbrowser/mozapp> to be a top-level frame.
-    rv = current->GetScriptableParent(getter_AddRefs(parent));
+    rv = current->GetParent(getter_AddRefs(parent));
     NS_ENSURE_SUCCESS(rv, rv);
 
     if (SameCOMIdentity(parent, current)) {
       // We're at the topmost content window. We already know the answer.
       *aResult = false;
       return NS_OK;
     }
 
@@ -207,19 +205,17 @@ ThirdPartyUtil::IsThirdPartyChannel(nsIC
   // If there is no window, the consumer kicking off the load didn't provide one
   // to the channel. This is limited to loads of certain types of resources. If
   // those loads require cookies, the forceAllowThirdPartyCookie property should
   // be set on the channel.
   nsCOMPtr<nsIDOMWindow> ourWin, parentWin;
   ctx->GetAssociatedWindow(getter_AddRefs(ourWin));
   if (!ourWin) return NS_ERROR_INVALID_ARG;
 
-  // We use GetScriptableParent rather than GetParent because we consider
-  // <iframe mozbrowser/mozapp> to be a top-level frame.
-  ourWin->GetScriptableParent(getter_AddRefs(parentWin));
+  ourWin->GetParent(getter_AddRefs(parentWin));
   NS_ENSURE_TRUE(parentWin, NS_ERROR_INVALID_ARG);
 
   // Check whether this is the document channel for this window (representing a
   // load of a new page). In that situation we want to avoid comparing
   // channelURI to ourWin, since what's in ourWin right now will be replaced as
   // the channel loads.  This covers the case of a freshly kicked-off load
   // (e.g. the user typing something in the location bar, or clicking on a
   // bookmark), where the window's URI hasn't yet been set, and will be bogus.