mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-29 15:52:07 +00:00
Bug 643352 keep-alive header syntax invalid r=bz
don't send the keep-alive request header. It is redundant to connection: keep-alive and we don't send the right syntax anyhow.
This commit is contained in:
parent
835fc0fb3a
commit
0277bf09fc
@ -394,15 +394,14 @@ nsHttpHandler::AddStandardRequestHeaders(nsHttpHeaderArray *request,
|
||||
//
|
||||
// However, we need to send something so that we can use keepalive
|
||||
// with HTTP/1.0 servers/proxies. We use "Proxy-Connection:" when
|
||||
// we're talking to an http proxy, and "Connection:" otherwise
|
||||
// we're talking to an http proxy, and "Connection:" otherwise.
|
||||
// We no longer send the Keep-Alive request header.
|
||||
|
||||
NS_NAMED_LITERAL_CSTRING(close, "close");
|
||||
NS_NAMED_LITERAL_CSTRING(keepAlive, "keep-alive");
|
||||
|
||||
const nsACString *connectionType = &close;
|
||||
if (caps & NS_HTTP_ALLOW_KEEPALIVE) {
|
||||
rv = request->SetHeader(nsHttp::Keep_Alive, nsPrintfCString("%u", mIdleTimeout));
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
connectionType = &keepAlive;
|
||||
} else if (useProxy) {
|
||||
// Bug 92006
|
||||
|
Loading…
Reference in New Issue
Block a user