summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorakalin@chromium.org <akalin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-09 18:05:03 +0000
committerakalin@chromium.org <akalin@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2013-04-09 18:05:03 +0000
commit7b3fee16f5697c2c8c0bc6b167cbbe0911288292 (patch)
treed148778a1846b4fd0c4056ef8ffab076083d8c30
parente70b5e0e9c9c515e1d8117b22e1e5ccf28d68b79 (diff)
downloadchromium_src-7b3fee16f5697c2c8c0bc6b167cbbe0911288292.zip
chromium_src-7b3fee16f5697c2c8c0bc6b167cbbe0911288292.tar.gz
chromium_src-7b3fee16f5697c2c8c0bc6b167cbbe0911288292.tar.bz2
Convert SpdyControlType to SpdyFrameType
Remove NUM_CONTROL_FRAME_TYPES (used to indicate a data frame) and replace it with a DATA enum value. Also add {FIRST,LAST}_CONTROL_TYPE enum values and use them in checks. Strengthen error checking in spdy_framer.cc -- previously, converting to an enum type may inadvertently convert an invalid value to a valid one. This lands server change 45004245. Also take advantage of new enum values in some test functions. Review URL: https://codereview.chromium.org/13849003 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@193145 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--net/spdy/buffered_spdy_framer.h2
-rw-r--r--net/spdy/spdy_frame_builder.cc4
-rw-r--r--net/spdy/spdy_frame_builder.h4
-rw-r--r--net/spdy/spdy_framer.cc45
-rw-r--r--net/spdy/spdy_framer.h9
-rw-r--r--net/spdy/spdy_framer_test.cc34
-rw-r--r--net/spdy/spdy_protocol.h8
-rw-r--r--net/spdy/spdy_test_util_spdy2.cc20
-rw-r--r--net/spdy/spdy_test_util_spdy2.h8
-rw-r--r--net/spdy/spdy_test_util_spdy3.cc20
-rw-r--r--net/spdy/spdy_test_util_spdy3.h8
11 files changed, 93 insertions, 69 deletions
diff --git a/net/spdy/buffered_spdy_framer.h b/net/spdy/buffered_spdy_framer.h
index 7615e83..f493b55 100644
--- a/net/spdy/buffered_spdy_framer.h
+++ b/net/spdy/buffered_spdy_framer.h
@@ -210,7 +210,7 @@ class NET_EXPORT_PRIVATE BufferedSpdyFramer
// Collection of fields from control frames that we need to
// buffer up from the spdy framer.
struct ControlFrameFields {
- SpdyControlType type;
+ SpdyFrameType type;
SpdyStreamId stream_id;
SpdyStreamId associated_stream_id;
SpdyPriority priority;
diff --git a/net/spdy/spdy_frame_builder.cc b/net/spdy/spdy_frame_builder.cc
index 64ecc30..73b9144 100644
--- a/net/spdy/spdy_frame_builder.cc
+++ b/net/spdy/spdy_frame_builder.cc
@@ -58,8 +58,10 @@ bool SpdyFrameBuilder::Seek(size_t length) {
}
bool SpdyFrameBuilder::WriteControlFrameHeader(const SpdyFramer& framer,
- SpdyControlType type,
+ SpdyFrameType type,
uint8 flags) {
+ DCHECK_GE(type, FIRST_CONTROL_TYPE);
+ DCHECK_LE(type, LAST_CONTROL_TYPE);
bool success = true;
if (framer.protocol_version() < 4) {
FlagsAndLength flags_length = CreateFlagsAndLength(
diff --git a/net/spdy/spdy_frame_builder.h b/net/spdy/spdy_frame_builder.h
index 1764beb..db67b0a 100644
--- a/net/spdy/spdy_frame_builder.h
+++ b/net/spdy/spdy_frame_builder.h
@@ -49,9 +49,9 @@ class NET_EXPORT_PRIVATE SpdyFrameBuilder {
// Populates this frame with a SPDY control frame header using
// version-specific information from the |framer| and length information from
- // capacity_.
+ // capacity_. The given type must be a control frame type.
bool WriteControlFrameHeader(const SpdyFramer& framer,
- SpdyControlType type,
+ SpdyFrameType type,
uint8 flags);
// Populates this frame with a SPDY data frame header using version-specific
diff --git a/net/spdy/spdy_framer.cc b/net/spdy/spdy_framer.cc
index d29a750..25ae837 100644
--- a/net/spdy/spdy_framer.cc
+++ b/net/spdy/spdy_framer.cc
@@ -146,7 +146,7 @@ void SpdyFramer::Reset() {
remaining_data_length_ = 0;
remaining_control_header_ = 0;
current_frame_buffer_length_ = 0;
- current_frame_type_ = NUM_CONTROL_FRAME_TYPES;
+ current_frame_type_ = DATA;
current_frame_flags_ = 0;
current_frame_length_ = 0;
current_frame_stream_id_ = kInvalidStream;
@@ -349,8 +349,10 @@ const char* SpdyFramer::StatusCodeToString(int status_code) {
return "UNKNOWN_STATUS";
}
-const char* SpdyFramer::ControlTypeToString(SpdyControlType type) {
+const char* SpdyFramer::FrameTypeToString(SpdyFrameType type) {
switch (type) {
+ case DATA:
+ return "DATA";
case SYN_STREAM:
return "SYN_STREAM";
case SYN_REPLY:
@@ -371,8 +373,6 @@ const char* SpdyFramer::ControlTypeToString(SpdyControlType type) {
return "WINDOW_UPDATE";
case CREDENTIAL:
return "CREDENTIAL";
- case NUM_CONTROL_FRAME_TYPES:
- break;
}
return "UNKNOWN_CONTROL_TYPE";
}
@@ -508,6 +508,10 @@ size_t SpdyFramer::ProcessCommonHeader(const char* data, size_t len) {
uint16 version = 0;
bool is_control_frame = false;
+ uint16 control_frame_type_field = DATA;
+ // ProcessControlFrameHeader() will set current_frame_type_ to the
+ // correct value if this is a valid control frame.
+ current_frame_type_ = DATA;
if (protocol_version() < 4) {
bool successful_read = reader->ReadUInt16(&version);
DCHECK(successful_read);
@@ -515,10 +519,9 @@ size_t SpdyFramer::ProcessCommonHeader(const char* data, size_t len) {
version &= ~kControlFlagMask; // Only valid for control frames.
if (is_control_frame) {
- uint16 frame_type_field;
- successful_read = reader->ReadUInt16(&frame_type_field);
- // We check for validity below in ProcessControlFrameHeader().
- current_frame_type_ = static_cast<SpdyControlType>(frame_type_field);
+ // We check control_frame_type_field's validity in
+ // ProcessControlFrameHeader().
+ successful_read = reader->ReadUInt16(&control_frame_type_field);
} else {
reader->Rewind();
successful_read = reader->ReadUInt31(&current_frame_stream_id_);
@@ -541,14 +544,13 @@ size_t SpdyFramer::ProcessCommonHeader(const char* data, size_t len) {
DCHECK(successful_read);
current_frame_length_ = length_field;
- uint8 frame_type_field = 0;
- successful_read = reader->ReadUInt8(&frame_type_field);
+ uint8 control_frame_type_field_uint8 = DATA;
+ successful_read = reader->ReadUInt8(&control_frame_type_field_uint8);
DCHECK(successful_read);
- if (frame_type_field != 0) {
- is_control_frame = true;
- // We check for validity below in ProcessControlFrameHeader().
- current_frame_type_ = static_cast<SpdyControlType>(frame_type_field);
- }
+ // We check control_frame_type_field's validity in
+ // ProcessControlFrameHeader().
+ control_frame_type_field = control_frame_type_field_uint8;
+ is_control_frame = (control_frame_type_field != DATA);
successful_read = reader->ReadUInt8(&current_frame_flags_);
DCHECK(successful_read);
@@ -619,23 +621,24 @@ size_t SpdyFramer::ProcessCommonHeader(const char* data, size_t len) {
<< " (expected " << spdy_version_ << ")";
set_error(SPDY_UNSUPPORTED_VERSION);
} else {
- ProcessControlFrameHeader();
+ ProcessControlFrameHeader(control_frame_type_field);
}
return original_len - len;
}
-void SpdyFramer::ProcessControlFrameHeader() {
+void SpdyFramer::ProcessControlFrameHeader(uint16 control_frame_type_field) {
DCHECK_EQ(SPDY_NO_ERROR, error_code_);
- DCHECK_LE(GetControlFrameHeaderSize(),
- current_frame_buffer_length_);
+ DCHECK_LE(GetControlFrameHeaderSize(), current_frame_buffer_length_);
- if (current_frame_type_ < SYN_STREAM ||
- current_frame_type_ >= NUM_CONTROL_FRAME_TYPES) {
+ if (control_frame_type_field < FIRST_CONTROL_TYPE ||
+ control_frame_type_field > LAST_CONTROL_TYPE) {
set_error(SPDY_INVALID_CONTROL_FRAME);
return;
}
+ current_frame_type_ = static_cast<SpdyFrameType>(control_frame_type_field);
+
if (current_frame_type_ == NOOP) {
DLOG(INFO) << "NOOP control frame found. Ignoring.";
CHANGE_STATE(SPDY_AUTO_RESET);
diff --git a/net/spdy/spdy_framer.h b/net/spdy/spdy_framer.h
index cebc320..4d13f53 100644
--- a/net/spdy/spdy_framer.h
+++ b/net/spdy/spdy_framer.h
@@ -495,7 +495,7 @@ class NET_EXPORT_PRIVATE SpdyFramer {
static const char* StateToString(int state);
static const char* ErrorCodeToString(int error_code);
static const char* StatusCodeToString(int status_code);
- static const char* ControlTypeToString(SpdyControlType type);
+ static const char* FrameTypeToString(SpdyFrameType type);
int protocol_version() const { return spdy_version_; }
@@ -553,7 +553,7 @@ class NET_EXPORT_PRIVATE SpdyFramer {
size_t ProcessDataFramePayload(const char* data, size_t len);
// Helpers for above internal breakouts from ProcessInput.
- void ProcessControlFrameHeader();
+ void ProcessControlFrameHeader(uint16 control_frame_type_field);
bool ProcessSetting(const char* data); // Always passed exactly 8 bytes.
// Retrieve serialized length of SpdyHeaderBlock. If compression is enabled, a
@@ -637,9 +637,8 @@ class NET_EXPORT_PRIVATE SpdyFramer {
// Number of bytes read into the current_frame_buffer_.
size_t current_frame_buffer_length_;
- // The type of the frame currently being read. Set to NUM_CONTROL_FRAME_TYPES
- // if currently processing a DATA frame.
- SpdyControlType current_frame_type_;
+ // The type of the frame currently being read.
+ SpdyFrameType current_frame_type_;
// The flags field of the frame currently being read.
uint8 current_frame_flags_;
diff --git a/net/spdy/spdy_framer_test.cc b/net/spdy/spdy_framer_test.cc
index 3ae8871a..97d00c3 100644
--- a/net/spdy/spdy_framer_test.cc
+++ b/net/spdy/spdy_framer_test.cc
@@ -286,7 +286,7 @@ class TestSpdyVisitor : public SpdyFramerVisitorInterface,
header_buffer_length_(0),
header_buffer_size_(kDefaultHeaderBufferSize),
header_stream_id_(-1),
- header_control_type_(NUM_CONTROL_FRAME_TYPES),
+ header_control_type_(DATA),
header_buffer_valid_(false),
credential_buffer_(new char[kDefaultCredentialBufferSize]),
credential_buffer_length_(0),
@@ -461,8 +461,10 @@ class TestSpdyVisitor : public SpdyFramerVisitorInterface,
}
}
- void InitHeaderStreaming(SpdyControlType header_control_type,
+ void InitHeaderStreaming(SpdyFrameType header_control_type,
SpdyStreamId stream_id) {
+ DCHECK_GE(header_control_type, FIRST_CONTROL_TYPE);
+ DCHECK_LE(header_control_type, LAST_CONTROL_TYPE);
memset(header_buffer_.get(), 0, header_buffer_size_);
header_buffer_length_ = 0;
header_stream_id_ = stream_id;
@@ -509,7 +511,7 @@ class TestSpdyVisitor : public SpdyFramerVisitorInterface,
size_t header_buffer_length_;
size_t header_buffer_size_;
SpdyStreamId header_stream_id_;
- SpdyControlType header_control_type_;
+ SpdyFrameType header_control_type_;
bool header_buffer_valid_;
SpdyHeaderBlock headers_;
@@ -3616,29 +3618,29 @@ TEST_P(SpdyFramerTest, StatusCodeToStringTest) {
SpdyFramer::StatusCodeToString(RST_STREAM_NUM_STATUS_CODES));
}
-TEST_P(SpdyFramerTest, ControlTypeToStringTest) {
+TEST_P(SpdyFramerTest, FrameTypeToStringTest) {
+ EXPECT_STREQ("DATA",
+ SpdyFramer::FrameTypeToString(DATA));
EXPECT_STREQ("SYN_STREAM",
- SpdyFramer::ControlTypeToString(SYN_STREAM));
+ SpdyFramer::FrameTypeToString(SYN_STREAM));
EXPECT_STREQ("SYN_REPLY",
- SpdyFramer::ControlTypeToString(SYN_REPLY));
+ SpdyFramer::FrameTypeToString(SYN_REPLY));
EXPECT_STREQ("RST_STREAM",
- SpdyFramer::ControlTypeToString(RST_STREAM));
+ SpdyFramer::FrameTypeToString(RST_STREAM));
EXPECT_STREQ("SETTINGS",
- SpdyFramer::ControlTypeToString(SETTINGS));
+ SpdyFramer::FrameTypeToString(SETTINGS));
EXPECT_STREQ("NOOP",
- SpdyFramer::ControlTypeToString(NOOP));
+ SpdyFramer::FrameTypeToString(NOOP));
EXPECT_STREQ("PING",
- SpdyFramer::ControlTypeToString(PING));
+ SpdyFramer::FrameTypeToString(PING));
EXPECT_STREQ("GOAWAY",
- SpdyFramer::ControlTypeToString(GOAWAY));
+ SpdyFramer::FrameTypeToString(GOAWAY));
EXPECT_STREQ("HEADERS",
- SpdyFramer::ControlTypeToString(HEADERS));
+ SpdyFramer::FrameTypeToString(HEADERS));
EXPECT_STREQ("WINDOW_UPDATE",
- SpdyFramer::ControlTypeToString(WINDOW_UPDATE));
+ SpdyFramer::FrameTypeToString(WINDOW_UPDATE));
EXPECT_STREQ("CREDENTIAL",
- SpdyFramer::ControlTypeToString(CREDENTIAL));
- EXPECT_STREQ("UNKNOWN_CONTROL_TYPE",
- SpdyFramer::ControlTypeToString(NUM_CONTROL_FRAME_TYPES));
+ SpdyFramer::FrameTypeToString(CREDENTIAL));
}
TEST_P(SpdyFramerTest, CatchProbableHttpResponse) {
diff --git a/net/spdy/spdy_protocol.h b/net/spdy/spdy_protocol.h
index 121507e..15b7dd0 100644
--- a/net/spdy/spdy_protocol.h
+++ b/net/spdy/spdy_protocol.h
@@ -251,9 +251,11 @@ const int kV3DictionarySize = arraysize(kV3Dictionary);
// accessors provided or call base::NetworkToHostX() functions.
// TODO(hkhalil): remove above note.
-// Types of Spdy Control Frames.
-enum SpdyControlType {
+// Types of SPDY frames.
+enum SpdyFrameType {
+ DATA = 0,
SYN_STREAM = 1,
+ FIRST_CONTROL_TYPE = SYN_STREAM,
SYN_REPLY,
RST_STREAM,
SETTINGS,
@@ -263,7 +265,7 @@ enum SpdyControlType {
HEADERS,
WINDOW_UPDATE,
CREDENTIAL,
- NUM_CONTROL_FRAME_TYPES
+ LAST_CONTROL_TYPE = CREDENTIAL
};
// Flags on data packets.
diff --git a/net/spdy/spdy_test_util_spdy2.cc b/net/spdy/spdy_test_util_spdy2.cc
index c990451..dd34079 100644
--- a/net/spdy/spdy_test_util_spdy2.cc
+++ b/net/spdy/spdy_test_util_spdy2.cc
@@ -17,6 +17,7 @@
#include "net/spdy/buffered_spdy_framer.h"
#include "net/spdy/spdy_http_utils.h"
#include "net/spdy/spdy_session.h"
+#include "testing/gtest/include/gtest/gtest.h"
namespace net {
namespace test_spdy2 {
@@ -77,6 +78,11 @@ SpdyFrame* ConstructSpdyFrame(const SpdyHeaderInfo& header_info,
BufferedSpdyFramer framer(kSpdyVersion2, header_info.compressed);
SpdyFrame* frame = NULL;
switch (header_info.kind) {
+ case DATA:
+ frame = framer.CreateDataFrame(header_info.id, header_info.data,
+ header_info.data_length,
+ header_info.data_flags);
+ break;
case SYN_STREAM:
frame = framer.CreateSynStream(header_info.id, header_info.assoc_id,
header_info.priority, 0,
@@ -95,9 +101,7 @@ SpdyFrame* ConstructSpdyFrame(const SpdyHeaderInfo& header_info,
header_info.compressed, headers.get());
break;
default:
- frame = framer.CreateDataFrame(header_info.id, header_info.data,
- header_info.data_length,
- header_info.data_flags);
+ ADD_FAILURE();
break;
}
return frame;
@@ -207,10 +211,12 @@ SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
bool compressed,
int stream_id,
RequestPriority request_priority,
- SpdyControlType type,
+ SpdyFrameType type,
SpdyControlFlags flags,
const char* const* kHeaders,
int kHeadersSize) {
+ EXPECT_GE(type, FIRST_CONTROL_TYPE);
+ EXPECT_LE(type, LAST_CONTROL_TYPE);
return ConstructSpdyControlFrame(extra_headers,
extra_header_count,
compressed,
@@ -228,11 +234,13 @@ SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
bool compressed,
SpdyStreamId stream_id,
RequestPriority request_priority,
- SpdyControlType type,
+ SpdyFrameType type,
SpdyControlFlags flags,
const char* const* kHeaders,
int kHeadersSize,
SpdyStreamId associated_stream_id) {
+ EXPECT_GE(type, FIRST_CONTROL_TYPE);
+ EXPECT_LE(type, LAST_CONTROL_TYPE);
const SpdyHeaderInfo kSynStartHeader = {
type, // Kind = Syn
stream_id, // Stream ID
@@ -807,7 +815,7 @@ SpdyURLRequestContext::SpdyURLRequestContext()
SpdyURLRequestContext::~SpdyURLRequestContext() {
}
-const SpdyHeaderInfo MakeSpdyHeader(SpdyControlType type) {
+const SpdyHeaderInfo MakeSpdyHeader(SpdyFrameType type) {
const SpdyHeaderInfo kHeader = {
type, // Kind = Syn
1, // Stream ID
diff --git a/net/spdy/spdy_test_util_spdy2.h b/net/spdy/spdy_test_util_spdy2.h
index d65df39..1f51a2f 100644
--- a/net/spdy/spdy_test_util_spdy2.h
+++ b/net/spdy/spdy_test_util_spdy2.h
@@ -33,7 +33,7 @@ namespace test_spdy2 {
// NOTE: In GCC, on a Mac, this can't be in an anonymous namespace!
// This struct holds information used to construct spdy control and data frames.
struct SpdyHeaderInfo {
- SpdyControlType kind;
+ SpdyFrameType kind;
SpdyStreamId id;
SpdyStreamId assoc_id;
SpdyPriority priority;
@@ -73,7 +73,7 @@ SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
bool compressed,
int stream_id,
RequestPriority request_priority,
- SpdyControlType type,
+ SpdyFrameType type,
SpdyControlFlags flags,
const char* const* kHeaders,
int kHeadersSize);
@@ -82,7 +82,7 @@ SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
bool compressed,
SpdyStreamId stream_id,
RequestPriority request_priority,
- SpdyControlType type,
+ SpdyFrameType type,
SpdyControlFlags flags,
const char* const* kHeaders,
int kHeadersSize,
@@ -310,7 +310,7 @@ class SpdyURLRequestContext : public URLRequestContext {
net::URLRequestContextStorage storage_;
};
-const SpdyHeaderInfo MakeSpdyHeader(SpdyControlType type);
+const SpdyHeaderInfo MakeSpdyHeader(SpdyFrameType type);
class SpdySessionPoolPeer {
public:
diff --git a/net/spdy/spdy_test_util_spdy3.cc b/net/spdy/spdy_test_util_spdy3.cc
index 1bfd4df..272a812 100644
--- a/net/spdy/spdy_test_util_spdy3.cc
+++ b/net/spdy/spdy_test_util_spdy3.cc
@@ -17,6 +17,7 @@
#include "net/spdy/buffered_spdy_framer.h"
#include "net/spdy/spdy_http_utils.h"
#include "net/spdy/spdy_session.h"
+#include "testing/gtest/include/gtest/gtest.h"
namespace net {
@@ -121,6 +122,11 @@ SpdyFrame* ConstructSpdyFrame(const SpdyHeaderInfo& header_info,
BufferedSpdyFramer framer(kSpdyVersion3, header_info.compressed);
SpdyFrame* frame = NULL;
switch (header_info.kind) {
+ case DATA:
+ frame = framer.CreateDataFrame(header_info.id, header_info.data,
+ header_info.data_length,
+ header_info.data_flags);
+ break;
case SYN_STREAM:
frame = framer.CreateSynStream(header_info.id, header_info.assoc_id,
header_info.priority,
@@ -140,9 +146,7 @@ SpdyFrame* ConstructSpdyFrame(const SpdyHeaderInfo& header_info,
header_info.compressed, headers.get());
break;
default:
- frame = framer.CreateDataFrame(header_info.id, header_info.data,
- header_info.data_length,
- header_info.data_flags);
+ ADD_FAILURE();
break;
}
return frame;
@@ -252,10 +256,12 @@ SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
bool compressed,
int stream_id,
RequestPriority request_priority,
- SpdyControlType type,
+ SpdyFrameType type,
SpdyControlFlags flags,
const char* const* kHeaders,
int kHeadersSize) {
+ EXPECT_GE(type, FIRST_CONTROL_TYPE);
+ EXPECT_LE(type, LAST_CONTROL_TYPE);
return ConstructSpdyControlFrame(extra_headers,
extra_header_count,
compressed,
@@ -273,11 +279,13 @@ SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
bool compressed,
SpdyStreamId stream_id,
RequestPriority request_priority,
- SpdyControlType type,
+ SpdyFrameType type,
SpdyControlFlags flags,
const char* const* kHeaders,
int kHeadersSize,
SpdyStreamId associated_stream_id) {
+ EXPECT_GE(type, FIRST_CONTROL_TYPE);
+ EXPECT_LE(type, LAST_CONTROL_TYPE);
const SpdyHeaderInfo kSynStartHeader = {
type, // Kind = Syn
stream_id, // Stream ID
@@ -859,7 +867,7 @@ SpdyURLRequestContext::SpdyURLRequestContext()
SpdyURLRequestContext::~SpdyURLRequestContext() {
}
-const SpdyHeaderInfo MakeSpdyHeader(SpdyControlType type) {
+const SpdyHeaderInfo MakeSpdyHeader(SpdyFrameType type) {
const SpdyHeaderInfo kHeader = {
type, // Kind = Syn
1, // Stream ID
diff --git a/net/spdy/spdy_test_util_spdy3.h b/net/spdy/spdy_test_util_spdy3.h
index fcc1c0d..61d8362 100644
--- a/net/spdy/spdy_test_util_spdy3.h
+++ b/net/spdy/spdy_test_util_spdy3.h
@@ -39,7 +39,7 @@ namespace test_spdy3 {
// NOTE: In GCC, on a Mac, this can't be in an anonymous namespace!
// This struct holds information used to construct spdy control and data frames.
struct SpdyHeaderInfo {
- SpdyControlType kind;
+ SpdyFrameType kind;
SpdyStreamId id;
SpdyStreamId assoc_id;
SpdyPriority priority;
@@ -112,7 +112,7 @@ SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
bool compressed,
int stream_id,
RequestPriority request_priority,
- SpdyControlType type,
+ SpdyFrameType type,
SpdyControlFlags flags,
const char* const* kHeaders,
int kHeadersSize);
@@ -121,7 +121,7 @@ SpdyFrame* ConstructSpdyControlFrame(const char* const extra_headers[],
bool compressed,
SpdyStreamId stream_id,
RequestPriority request_priority,
- SpdyControlType type,
+ SpdyFrameType type,
SpdyControlFlags flags,
const char* const* kHeaders,
int kHeadersSize,
@@ -353,7 +353,7 @@ class SpdyURLRequestContext : public URLRequestContext {
net::URLRequestContextStorage storage_;
};
-const SpdyHeaderInfo MakeSpdyHeader(SpdyControlType type);
+const SpdyHeaderInfo MakeSpdyHeader(SpdyFrameType type);
class SpdySessionPoolPeer {
public: