Bug 1144988. r=bz a=lmandel
authorKyle Huey <khuey@kylehuey.com>
Fri, 20 Mar 2015 19:15:13 -0700
changeset 201127 72dd5f98842865882e06e775e0b316b10e609c42
parent 201126 854698de78a277893af5acefcedbe99bcb573c75
child 201130 2722f5ce1390165446e9e9ff51dc2156d34a5fe4
push id237
push userkhuey@mozilla.com
push dateSat, 21 Mar 2015 02:38:13 +0000
treeherdermozilla-esr31@72dd5f988428 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbz, lmandel
bugs1144988
milestone31.5.2esrpre
Bug 1144988. r=bz a=lmandel
docshell/base/nsDocShell.cpp
--- a/docshell/base/nsDocShell.cpp
+++ b/docshell/base/nsDocShell.cpp
@@ -1317,19 +1317,20 @@ nsDocShell::LoadURI(nsIURI * aURI,
                     bool aFirstParty)
 {
     NS_PRECONDITION(aLoadInfo || (aLoadFlags & EXTRA_LOAD_FLAGS) == 0,
                     "Unexpected flags");
     NS_PRECONDITION((aLoadFlags & 0xf) == 0, "Should not have these flags set");
     
     // Note: we allow loads to get through here even if mFiredUnloadEvent is
     // true; that case will get handled in LoadInternal or LoadHistoryEntry.
-    if (IsPrintingOrPP()) {
+    if (IsPrintingOrPP() || mBlockNavigation) {
       return NS_OK; // JS may not handle returning of an error code
     }
+
     nsCOMPtr<nsIURI> referrer;
     nsCOMPtr<nsIInputStream> postStream;
     nsCOMPtr<nsIInputStream> headersStream;
     nsCOMPtr<nsISupports> owner;
     bool inheritOwner = false;
     bool ownerIsExplicit = false;
     bool sendReferrer = true;
     bool isSrcdoc = false;