Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: chrome/content/httpd.js

Issue 6309214725079040: Issue 1409 - Fix some errors in adblockplustest (Closed)
Patch Set: Created Sept. 19, 2014, 10:35 a.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | chrome/content/tests/filterStorage.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/content/httpd.js
===================================================================
--- a/chrome/content/httpd.js
+++ b/chrome/content/httpd.js
@@ -700,19 +700,17 @@
// NSISUPPORTS
//
// see nsISupports.QueryInterface
//
QueryInterface: function(iid)
{
- if (iid.equals(Ci.nsIHttpServer) ||
- iid.equals(Ci.nsIServerSocketListener) ||
- iid.equals(Ci.nsISupports))
+ if (iid.equals(Ci.nsIServerSocketListener) || iid.equals(Ci.nsISupports))
return this;
throw Cr.NS_ERROR_NO_INTERFACE;
},
// NON-XPCOM PUBLIC API
@@ -2133,17 +2131,17 @@
var headerFile = file.parent;
headerFile.append(name + HEADERS_SUFFIX);
if (!headerFile.exists())
return;
const PR_RDONLY = 0x01;
- var fis = new FileInputStream(headerFile, PR_RDONLY, 0444,
+ var fis = new FileInputStream(headerFile, PR_RDONLY, 0o444,
Ci.nsIFileInputStream.CLOSE_ON_EOF);
try
{
var lis = new ConverterInputStream(fis, "UTF-8", 1024, 0x0);
lis.QueryInterface(Ci.nsIUnicharLineInputStream);
var line = {value: ""};
@@ -2668,17 +2666,17 @@
*/
_writeFileResponse: function(metadata, file, response, offset, count)
{
const PR_RDONLY = 0x01;
var type = this._getTypeFromFile(file);
if (type === SJS_TYPE)
{
- var fis = new FileInputStream(file, PR_RDONLY, 0444,
+ var fis = new FileInputStream(file, PR_RDONLY, 0o444,
Ci.nsIFileInputStream.CLOSE_ON_EOF);
try
{
var sis = new ScriptableInputStream(fis);
var s = Cu.Sandbox(gGlobalObject);
s.importFunction(dump, "dump");
@@ -2762,17 +2760,17 @@
false);
}
catch (e) { /* lastModifiedTime threw, ignore */ }
response.setHeader("Content-Type", type, false);
maybeAddHeaders(file, metadata, response);
response.setHeader("Content-Length", "" + count, false);
- var fis = new FileInputStream(file, PR_RDONLY, 0444,
+ var fis = new FileInputStream(file, PR_RDONLY, 0o444,
Ci.nsIFileInputStream.CLOSE_ON_EOF);
offset = offset || 0;
count = count || file.fileSize;
NS_ASSERT(offset === 0 || offset < file.fileSize, "bad offset");
NS_ASSERT(count >= 0, "bad count");
NS_ASSERT(offset + count <= file.fileSize, "bad total data size");
« no previous file with comments | « no previous file | chrome/content/tests/filterStorage.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld