Skip to content

Commit 6231c15

Browse files
committed
ff: gc() is not defined
1 parent 6bbafd4 commit 6231c15

File tree

1 file changed

+15
-19
lines changed
  • javascript/firefox-driver/extension/components

1 file changed

+15
-19
lines changed

Diff for: javascript/firefox-driver/extension/components/httpd.js

+15-19
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,7 @@ function toDateString(date)
286286
{
287287
var hrs = date.getUTCHours();
288288
var rv = (hrs < 10) ? "0" + hrs : hrs;
289-
289+
290290
var mins = date.getUTCMinutes();
291291
rv += ":";
292292
rv += (mins < 10) ? "0" + mins : mins;
@@ -833,10 +833,6 @@ nsHttpServer.prototype =
833833
// Fire a pending server-stopped notification if it's our responsibility.
834834
if (!this._hasOpenConnections() && this._socketClosed)
835835
this._notifyStopped();
836-
// Bug 508125: Add a GC here else we'll use gigabytes of memory running
837-
// mochitests. We can't rely on xpcshell doing an automated GC, as that
838-
// would interfere with testing GC stuff...
839-
gc();
840836
},
841837

842838
/**
@@ -869,7 +865,7 @@ const HOST_REGEX =
869865
// toplabel
870866
"[a-z](?:[a-z0-9-]*[a-z0-9])?" +
871867
"|" +
872-
// IPv4 address
868+
// IPv4 address
873869
"\\d+\\.\\d+\\.\\d+\\.\\d+" +
874870
")$",
875871
"i");
@@ -1080,7 +1076,7 @@ ServerIdentity.prototype =
10801076
// Not the default primary location, nothing special to do here
10811077
this.remove("http", "127.0.0.1", this._defaultPort);
10821078
}
1083-
1079+
10841080
// This is a *very* tricky bit of reasoning here; make absolutely sure the
10851081
// tests for this code pass before you commit changes to it.
10861082
if (this._primaryScheme == "http" &&
@@ -1185,7 +1181,7 @@ function Connection(input, output, server, port, outgoingPort, number)
11851181
this._processed = false;
11861182

11871183
/** whether or not 1st line of request has been received */
1188-
this._requestStarted = false;
1184+
this._requestStarted = false;
11891185
}
11901186
Connection.prototype =
11911187
{
@@ -1529,7 +1525,7 @@ RequestReader.prototype =
15291525
this._handleResponse();
15301526
return true;
15311527
}
1532-
1528+
15331529
return false;
15341530
}
15351531
catch (e)
@@ -2233,7 +2229,7 @@ function maybeAddHeaders(file, metadata, response)
22332229
code = status.substring(0, space);
22342230
description = status.substring(space + 1, status.length);
22352231
}
2236-
2232+
22372233
response.setStatusLine(metadata.httpVersion, parseInt(code, 10), description);
22382234

22392235
line.value = "";
@@ -3164,7 +3160,7 @@ ServerHandler.prototype =
31643160
dumpn("*** error in request: " + errorCode);
31653161

31663162
this._handleError(errorCode, new Request(connection.port), response);
3167-
},
3163+
},
31683164

31693165
/**
31703166
* Handles a request which generates the given error code, using the
@@ -3413,7 +3409,7 @@ ServerHandler.prototype =
34133409

34143410
if (metadata.queryString)
34153411
body += "?" + metadata.queryString;
3416-
3412+
34173413
body += " HTTP/" + metadata.httpVersion + "\r\n";
34183414

34193415
var headEnum = metadata.headers;
@@ -4966,17 +4962,17 @@ nsHttpHeaders.prototype =
49664962
var value = headerUtils.normalizeFieldValue(fieldValue);
49674963

49684964
// The following three headers are stored as arrays because their real-world
4969-
// syntax prevents joining individual headers into a single header using
4965+
// syntax prevents joining individual headers into a single header using
49704966
// ",". See also <http://hg.mozilla.org/mozilla-central/diff/9b2a99adc05e/netwerk/protocol/http/src/nsHttpHeaderArray.cpp#l77>
49714967
if (merge && name in this._headers)
49724968
{
49734969
if (name === "www-authenticate" ||
49744970
name === "proxy-authenticate" ||
4975-
name === "set-cookie")
4971+
name === "set-cookie")
49764972
{
49774973
this._headers[name].push(value);
49784974
}
4979-
else
4975+
else
49804976
{
49814977
this._headers[name][0] += "," + value;
49824978
NS_ASSERT(this._headers[name].length === 1,
@@ -4999,8 +4995,8 @@ nsHttpHeaders.prototype =
49994995
* @returns string
50004996
* the field value for the given header, possibly with non-semantic changes
50014997
* (i.e., leading/trailing whitespace stripped, whitespace runs replaced
5002-
* with spaces, etc.) at the option of the implementation; multiple
5003-
* instances of the header will be combined with a comma, except for
4998+
* with spaces, etc.) at the option of the implementation; multiple
4999+
* instances of the header will be combined with a comma, except for
50045000
* the three headers noted in the description of getHeaderValues
50055001
*/
50065002
getHeader: function(fieldName)
@@ -5262,7 +5258,7 @@ Request.prototype =
52625258
//
52635259
// see nsIPropertyBag.getProperty
52645260
//
5265-
getProperty: function(name)
5261+
getProperty: function(name)
52665262
{
52675263
this._ensurePropertyBag();
52685264
return this._bag.getProperty(name);
@@ -5284,7 +5280,7 @@ Request.prototype =
52845280

52855281

52865282
// PRIVATE IMPLEMENTATION
5287-
5283+
52885284
/** Ensures a property bag has been created for ad-hoc behaviors. */
52895285
_ensurePropertyBag: function()
52905286
{

0 commit comments

Comments
 (0)