diff options
author | janekptacijarabaci <janekptacijarabaci@seznam.cz> | 2018-04-30 23:52:21 +0200 |
---|---|---|
committer | janekptacijarabaci <janekptacijarabaci@seznam.cz> | 2018-04-30 23:52:21 +0200 |
commit | e0a24e6d4f43a5f240f4c389e57a23a7a32f84ab (patch) | |
tree | 8c57de672260fec82ca55da3c2e2ef24cb184030 /browser/base/content/nsContextMenu.js | |
parent | 73b55c16d642156c58142d1ce4cfb79229cfadb0 (diff) | |
download | UXP-e0a24e6d4f43a5f240f4c389e57a23a7a32f84ab.tar UXP-e0a24e6d4f43a5f240f4c389e57a23a7a32f84ab.tar.gz UXP-e0a24e6d4f43a5f240f4c389e57a23a7a32f84ab.tar.lz UXP-e0a24e6d4f43a5f240f4c389e57a23a7a32f84ab.tar.xz UXP-e0a24e6d4f43a5f240f4c389e57a23a7a32f84ab.zip |
Bug 1343279 - Use SystemPrincipal when loading canvasToBlobURL
Diffstat (limited to 'browser/base/content/nsContextMenu.js')
-rw-r--r-- | browser/base/content/nsContextMenu.js | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/browser/base/content/nsContextMenu.js b/browser/base/content/nsContextMenu.js index ddf695202..cd93a803c 100644 --- a/browser/base/content/nsContextMenu.js +++ b/browser/base/content/nsContextMenu.js @@ -1147,10 +1147,12 @@ nsContextMenu.prototype = { // Change current window to the URL of the image, video, or audio. viewMedia: function(e) { let referrerURI = gContextMenuContentData.documentURIObject; + let systemPrincipal = Services.scriptSecurityManager.getSystemPrincipal(); if (this.onCanvas) { this._canvasToBlobURL(this.target).then(function(blobURL) { openUILink(blobURL, e, { disallowInheritPrincipal: true, - referrerURI: referrerURI }); + referrerURI: referrerURI, + originPrincipal: systemPrincipal}); }, Cu.reportError); } else { |