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

Unified Diff: net/quic/quic_protocol.cc

Issue 180723003: Land Recent QUIC Changes. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix unintialized memory error Created 6 years, 10 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/quic/quic_protocol.h ('k') | net/quic/quic_received_packet_manager.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_protocol.cc
diff --git a/net/quic/quic_protocol.cc b/net/quic/quic_protocol.cc
index 1d673d9ae405e2d77d01906b153be271cd0b1ecc..e56522de4e7e3332110ad364f67bfeadf4335fab 100644
--- a/net/quic/quic_protocol.cc
+++ b/net/quic/quic_protocol.cc
@@ -159,6 +159,8 @@ QuicTag QuicVersionToQuicTag(const QuicVersion version) {
return MakeQuicTag('Q', '0', '1', '4');
case QUIC_VERSION_15:
return MakeQuicTag('Q', '0', '1', '5');
+ case QUIC_VERSION_16:
+ return MakeQuicTag('Q', '0', '1', '6');
default:
// This shold be an ERROR because we should never attempt to convert an
// invalid QuicVersion to be written to the wire.
@@ -189,6 +191,7 @@ string QuicVersionToString(const QuicVersion version) {
RETURN_STRING_LITERAL(QUIC_VERSION_13);
RETURN_STRING_LITERAL(QUIC_VERSION_14);
RETURN_STRING_LITERAL(QUIC_VERSION_15);
+ RETURN_STRING_LITERAL(QUIC_VERSION_16);
default:
return "QUIC_VERSION_UNSUPPORTED";
}
@@ -249,12 +252,12 @@ void InsertMissingPacketsBetween(ReceivedPacketInfo* received_info,
}
}
-SentPacketInfo::SentPacketInfo()
+QuicStopWaitingFrame::QuicStopWaitingFrame()
: entropy_hash(0),
least_unacked(0) {
}
-SentPacketInfo::~SentPacketInfo() {}
+QuicStopWaitingFrame::~QuicStopWaitingFrame() {}
QuicAckFrame::QuicAckFrame() {}
@@ -321,6 +324,11 @@ QuicFrame::QuicFrame(QuicCongestionFeedbackFrame* frame)
congestion_feedback_frame(frame) {
}
+QuicFrame::QuicFrame(QuicStopWaitingFrame* frame)
+ : type(STOP_WAITING_FRAME),
+ stop_waiting_frame(frame) {
+}
+
QuicFrame::QuicFrame(QuicRstStreamFrame* frame)
: type(RST_STREAM_FRAME),
rst_stream_frame(frame) {
@@ -348,7 +356,7 @@ QuicFrame::QuicFrame(QuicBlockedFrame* frame)
QuicFecData::QuicFecData() : fec_group(0) {}
-ostream& operator<<(ostream& os, const SentPacketInfo& sent_info) {
+ostream& operator<<(ostream& os, const QuicStopWaitingFrame& sent_info) {
os << "entropy_hash: " << static_cast<int>(sent_info.entropy_hash)
<< " least_unacked: " << sent_info.least_unacked;
return os;
@@ -414,6 +422,10 @@ ostream& operator<<(ostream& os, const QuicFrame& frame) {
<< *(frame.congestion_feedback_frame);
break;
}
+ case STOP_WAITING_FRAME: {
+ os << "type { STOP_WAITING_FRAME } " << *(frame.stop_waiting_frame);
+ break;
+ }
default: {
LOG(ERROR) << "Unknown frame type: " << frame.type;
break;
@@ -621,6 +633,9 @@ RetransmittableFrames::~RetransmittableFrames() {
case CONGESTION_FEEDBACK_FRAME:
delete it->congestion_feedback_frame;
break;
+ case STOP_WAITING_FRAME:
+ delete it->stop_waiting_frame;
+ break;
case RST_STREAM_FRAME:
delete it->rst_stream_frame;
break;
« no previous file with comments | « net/quic/quic_protocol.h ('k') | net/quic/quic_received_packet_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698