diff --git a/application/basilisk/extensions/pdfjs/content/PdfJsNetwork.jsm b/application/basilisk/extensions/pdfjs/content/PdfJsNetwork.jsm index c3aefecb26..4f85188c99 100644 --- a/application/basilisk/extensions/pdfjs/content/PdfJsNetwork.jsm +++ b/application/basilisk/extensions/pdfjs/content/PdfJsNetwork.jsm @@ -95,6 +95,7 @@ var NetworkManager = (function NetworkManagerClosure() { var rangeStr = args.begin + '-' + (args.end - 1); xhr.setRequestHeader('Range', 'bytes=' + rangeStr); pendingRequest.expectedStatus = 206; + xhr.channel.QueryInterface(Ci.nsIHttpChannel).redirectionLimit = 0; } else { pendingRequest.expectedStatus = 200; } diff --git a/dom/base/nsContentUtils.cpp b/dom/base/nsContentUtils.cpp index a347525545..107daaede6 100644 --- a/dom/base/nsContentUtils.cpp +++ b/dom/base/nsContentUtils.cpp @@ -9341,62 +9341,6 @@ nsContentUtils::SetScrollbarsVisibility(nsIDocShell* aDocShell, bool aVisible) } } -/* static */ void -nsContentUtils::GetPresentationURL(nsIDocShell* aDocShell, nsAString& aPresentationUrl) -{ - MOZ_ASSERT(aDocShell); - - // Simulate receiver context for web platform test - if (Preferences::GetBool("dom.presentation.testing.simulate-receiver")) { - nsCOMPtr doc; - - nsCOMPtr docShellWin = - do_QueryInterface(aDocShell->GetScriptGlobalObject()); - if (docShellWin) { - doc = docShellWin->GetExtantDoc(); - } - - if (NS_WARN_IF(!doc)) { - return; - } - - nsCOMPtr uri = doc->GetDocumentURI(); - if (NS_WARN_IF(!uri)) { - return; - } - - nsAutoCString uriStr; - uri->GetSpec(uriStr); - aPresentationUrl = NS_ConvertUTF8toUTF16(uriStr); - return; - } - - if (XRE_IsContentProcess()) { - nsCOMPtr sameTypeRoot; - aDocShell->GetSameTypeRootTreeItem(getter_AddRefs(sameTypeRoot)); - nsCOMPtr root; - aDocShell->GetRootTreeItem(getter_AddRefs(root)); - if (sameTypeRoot.get() == root.get()) { - // presentation URL is stored in TabChild for the top most - //