Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(616)

Unified Diff: net/spdy/spdy_test_util_spdy3.cc

Issue 9705046: Switch CreateSpdyHeadersFromHttpRequest to construct the correct headers based on the spdy protocol… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix raman's comments. Created 8 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « net/spdy/spdy_stream_spdy3_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/spdy/spdy_test_util_spdy3.cc
diff --git a/net/spdy/spdy_test_util_spdy3.cc b/net/spdy/spdy_test_util_spdy3.cc
index 25094c8bf25a4f194224d22855674752f2edc0cc..1958fdaf0b91cdde54b2f531a57ec6d8c805db3f 100644
--- a/net/spdy/spdy_test_util_spdy3.cc
+++ b/net/spdy/spdy_test_util_spdy3.cc
@@ -373,15 +373,15 @@ spdy::SpdyFrame* ConstructSpdyGet(const char* const url,
host.get()[str_host.size()] = '\0';
const char* const headers[] = {
- "method",
+ ":method",
"GET",
- "url",
+ ":path",
req.get(),
- "host",
+ ":host",
host.get(),
- "scheme",
+ ":scheme",
scheme.get(),
- "version",
+ ":version",
"HTTP/1.1"
};
return ConstructSpdyPacket(
@@ -416,16 +416,16 @@ spdy::SpdyFrame* ConstructSpdyGet(const char* const extra_headers[],
RequestPriority request_priority,
bool direct) {
const char* const kStandardGetHeaders[] = {
- "method",
+ ":method",
"GET",
- "url",
- (direct ? "/" : "http://www.google.com/"),
- "host",
+ ":host",
"www.google.com",
- "scheme",
+ ":scheme",
"http",
- "version",
- "HTTP/1.1"
+ ":version",
+ "HTTP/1.1",
+ ":path",
+ (direct ? "/" : "/")
};
return ConstructSpdyControlFrame(extra_headers,
extra_header_count,
@@ -443,10 +443,10 @@ spdy::SpdyFrame* ConstructSpdyConnect(const char* const extra_headers[],
int extra_header_count,
int stream_id) {
const char* const kConnectHeaders[] = {
- "method", "CONNECT",
- "url", "www.google.com:443",
- "host", "www.google.com",
- "version", "HTTP/1.1",
+ ":method", "CONNECT",
+ ":path", "www.google.com:443",
+ ":host", "www.google.com",
+ ":version", "HTTP/1.1",
};
return ConstructSpdyControlFrame(extra_headers,
extra_header_count,
@@ -669,15 +669,15 @@ spdy::SpdyFrame* ConstructSpdyPost(int64 content_length,
int extra_header_count) {
std::string length_str = base::Int64ToString(content_length);
const char* post_headers[] = {
- "method",
+ ":method",
"POST",
- "url",
+ ":path",
"/",
- "host",
+ ":host",
"www.google.com",
- "scheme",
+ ":scheme",
"http",
- "version",
+ ":version",
"HTTP/1.1",
"content-length",
length_str.c_str()
@@ -700,15 +700,15 @@ spdy::SpdyFrame* ConstructSpdyPost(int64 content_length,
spdy::SpdyFrame* ConstructChunkedSpdyPost(const char* const extra_headers[],
int extra_header_count) {
const char* post_headers[] = {
- "method",
+ ":method",
"POST",
- "url",
+ ":path",
"/",
- "host",
+ ":host",
"www.google.com",
- "scheme",
+ ":scheme",
"http",
- "version",
+ ":version",
"HTTP/1.1"
};
return ConstructSpdyControlFrame(extra_headers,
« no previous file with comments | « net/spdy/spdy_stream_spdy3_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698