Backed out changeset c8199958741a (bug 1352146)

This commit is contained in:
Sebastian Hengst 2017-04-08 01:44:22 +02:00
Родитель f463069928
Коммит 2bb432f54a
3 изменённых файлов: 0 добавлений и 29 удалений

Просмотреть файл

@ -1022,19 +1022,6 @@ Http2Stream::ConvertResponseHeaders(Http2Decompressor *decompressor,
nsresult errcode;
httpResponseCode = statusString.ToInteger(&errcode);
// Ensure the :status is just an HTTP status code
// https://tools.ietf.org/html/rfc7540#section-8.1.2.4
// https://bugzilla.mozilla.org/show_bug.cgi?id=1352146
nsAutoCString parsedStatusString;
parsedStatusString.AppendInt(httpResponseCode);
if (!parsedStatusString.Equals(statusString)) {
LOG3(("Http2Stream::ConvertResposeHeaders %p status %s is not just a code",
this, statusString.BeginReading()));
// Results in stream reset with PROTOCOL_ERROR
return NS_ERROR_ILLEGAL_VALUE;
}
LOG3(("Http2Stream::ConvertResponseHeaders %p response code %d\n", this, httpResponseCode));
if (mIsTunnel) {
LOG3(("Http2Stream %p Tunnel Response code %d", this, httpResponseCode));

Просмотреть файл

@ -951,13 +951,6 @@ function test_http2_push_userContext3() {
chan.asyncOpen2(listener);
}
function test_http2_status_phrase() {
var chan = makeChan("https://localhost:" + serverPort + "/statusphrase");
var listener = new Http2CheckListener();
listener.shouldSucceed = false;
chan.asyncOpen2(listener);
}
function test_complete() {
resetPrefs();
do_test_pending();
@ -1003,7 +996,6 @@ var tests = [ test_http2_post_big
, test_http2_illegalhpackhard
, test_http2_folded_header
, test_http2_empty_data
, test_http2_status_phrase
// Add new tests above here - best to add new tests before h1
// streams get too involved
// These next two must always come in this order

Просмотреть файл

@ -799,14 +799,6 @@ function handleRequest(req, res) {
res.setHeader("x-client-port", req.remotePort);
}
else if (u.pathname === "/statusphrase") {
// Fortunately, the node-http2 API is dumb enough to allow this right on
// through, so we can easily test rejecting this on gecko's end.
res.writeHead("200 OK");
res.end(content);
return;
}
res.setHeader('Content-Type', 'text/html');
if (req.httpVersionMajor != 2) {
res.setHeader('Connection', 'close');