Bug 1131455 - about:sync-log assertion failure: newly created channel must have a loadinfo attached (r=rnewman)

This commit is contained in:
Christoph Kerschbaumer 2015-02-17 19:54:12 -08:00
parent c27209dc7b
commit 0563c33f46

View File

@ -177,15 +177,11 @@ AboutWeaveLog.prototype = {
return 0;
},
newChannel: function(aURI) {
newChannel: function(aURI, aLoadInfo) {
let dir = FileUtils.getDir("ProfD", ["weave", "logs"], true);
let uri = Services.io.newFileURI(dir);
let channel = Services.io.newChannelFromURI2(uri,
null, // aLoadingNode
Services.scriptSecurityManager.getSystemPrincipal(),
null, // aTriggeringPrincipal
Ci.nsILoadInfo.SEC_NORMAL,
Ci.nsIContentPolicy.TYPE_OTHER);
let channel = Services.io.newChannelFromURIWithLoadInfo(uri, aLoadInfo);
channel.originalURI = aURI;
// Ensure that the about page has the same privileges as a regular directory