mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-12-02 01:48:05 +00:00
Backed out changeset 0080bcc1cecc (bug 1223225) for Windows 8 PGO bc1 bustage ON A CLOSED TREE
This commit is contained in:
parent
70eb23339b
commit
f5c71b51f3
@ -1344,12 +1344,15 @@ nsContextMenu.prototype = {
|
||||
// * this.principal - as the loadingPrincipal
|
||||
// for now lets use systemPrincipal to bypass mixedContentBlocker
|
||||
// checks after redirects, see bug: 1136055
|
||||
var channel = NetUtil.newChannel({
|
||||
uri: makeURI(linkURL),
|
||||
loadUsingSystemPrincipal: true,
|
||||
securityFlags: Ci.nsILoadInfo.SEC_ALLOW_CROSS_ORIGIN_DATA_IS_NULL
|
||||
});
|
||||
|
||||
var ioService = Cc["@mozilla.org/network/io-service;1"].
|
||||
getService(Ci.nsIIOService);
|
||||
var principal = Services.scriptSecurityManager.getSystemPrincipal();
|
||||
var channel = ioService.newChannelFromURI2(makeURI(linkURL),
|
||||
null, // aLoadingNode
|
||||
principal, // aLoadingPrincipal
|
||||
null, // aTriggeringPrincipal
|
||||
Ci.nsILoadInfo.SEC_NORMAL,
|
||||
Ci.nsIContentPolicy.TYPE_OTHER);
|
||||
if (linkDownload)
|
||||
channel.contentDispositionFilename = linkDownload;
|
||||
if (channel instanceof Ci.nsIPrivateBrowsingChannel) {
|
||||
@ -1382,7 +1385,7 @@ nsContextMenu.prototype = {
|
||||
timer.TYPE_ONE_SHOT);
|
||||
|
||||
// kick off the channel with our proxy object as the listener
|
||||
channel.asyncOpen2(new saveAsListener());
|
||||
channel.asyncOpen(new saveAsListener(), null);
|
||||
},
|
||||
|
||||
// Save URL of clicked-on link.
|
||||
|
Loading…
Reference in New Issue
Block a user