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 c644d095b3
commit a6887de13f

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