| Index: net/spdy/spdy_http_utils.cc
|
| diff --git a/net/spdy/spdy_http_utils.cc b/net/spdy/spdy_http_utils.cc
|
| index 448c82ffd3ca9a2fc06f947f706e6082c36f8956..77ed5b5ad31f2f35cab04952201d325f55743ed1 100644
|
| --- a/net/spdy/spdy_http_utils.cc
|
| +++ b/net/spdy/spdy_http_utils.cc
|
| @@ -88,7 +88,6 @@ void CreateSpdyHeadersFromHttpRequest(const HttpRequestInfo& info,
|
| SpdyHeaderBlock* headers,
|
| SpdyMajorVersion protocol_version,
|
| bool direct) {
|
| -
|
| HttpRequestHeaders::Iterator it(request_headers);
|
| while (it.GetNext()) {
|
| std::string name = StringToLowerASCII(it.name());
|
| @@ -129,8 +128,7 @@ void CreateSpdyHeadersFromHttpRequest(const HttpRequestInfo& info,
|
| }
|
| }
|
|
|
| -COMPILE_ASSERT(HIGHEST - LOWEST < 4 &&
|
| - HIGHEST - MINIMUM_PRIORITY < 5,
|
| +COMPILE_ASSERT(HIGHEST - LOWEST < 4 && HIGHEST - MINIMUM_PRIORITY < 5,
|
| request_priority_incompatible_with_spdy);
|
|
|
| SpdyPriority ConvertRequestPriorityToSpdyPriority(
|
| @@ -151,14 +149,15 @@ SpdyPriority ConvertRequestPriorityToSpdyPriority(
|
| }
|
| }
|
|
|
| -NET_EXPORT_PRIVATE RequestPriority ConvertSpdyPriorityToRequestPriority(
|
| - SpdyPriority priority,
|
| - SpdyMajorVersion protocol_version) {
|
| +NET_EXPORT_PRIVATE RequestPriority
|
| +ConvertSpdyPriorityToRequestPriority(SpdyPriority priority,
|
| + SpdyMajorVersion protocol_version) {
|
| // Handle invalid values gracefully, and pick LOW to map 2 back
|
| // to for SPDY/2.
|
| SpdyPriority idle_cutoff = (protocol_version == SPDY2) ? 3 : 5;
|
| - return (priority >= idle_cutoff) ?
|
| - IDLE : static_cast<RequestPriority>(HIGHEST - priority);
|
| + return (priority >= idle_cutoff)
|
| + ? IDLE
|
| + : static_cast<RequestPriority>(HIGHEST - priority);
|
| }
|
|
|
| GURL GetUrlFromHeaderBlock(const SpdyHeaderBlock& headers,
|
| @@ -166,17 +165,19 @@ GURL GetUrlFromHeaderBlock(const SpdyHeaderBlock& headers,
|
| bool pushed) {
|
| // SPDY 2 server push urls are specified in a single "url" header.
|
| if (pushed && protocol_version == SPDY2) {
|
| - std::string url;
|
| - SpdyHeaderBlock::const_iterator it;
|
| - it = headers.find("url");
|
| - if (it != headers.end())
|
| - url = it->second;
|
| - return GURL(url);
|
| + std::string url;
|
| + SpdyHeaderBlock::const_iterator it;
|
| + it = headers.find("url");
|
| + if (it != headers.end())
|
| + url = it->second;
|
| + return GURL(url);
|
| }
|
|
|
| const char* scheme_header = protocol_version >= SPDY3 ? ":scheme" : "scheme";
|
| - const char* host_header = protocol_version >= SPDY4 ? ":authority" :
|
| - (protocol_version >= SPDY3 ? ":host" : "host");
|
| + const char* host_header =
|
| + protocol_version >= SPDY4
|
| + ? ":authority"
|
| + : (protocol_version >= SPDY3 ? ":host" : "host");
|
| const char* path_header = protocol_version >= SPDY3 ? ":path" : "url";
|
|
|
| std::string scheme;
|
|
|