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

Unified Diff: net/quic/quic_connection.cc

Issue 1335443002: Landing Recent QUIC changes until 8/26/2015 19:47 UTC. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 3 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/congestion_control/tcp_cubic_sender_test.cc ('k') | net/quic/quic_flags.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: net/quic/quic_connection.cc
diff --git a/net/quic/quic_connection.cc b/net/quic/quic_connection.cc
index f663111c2cdaf13369d6d438ac02004586c5511f..1bfc6ff5211c823369c8120d1d0449a75196f889 100644
--- a/net/quic/quic_connection.cc
+++ b/net/quic/quic_connection.cc
@@ -1457,11 +1457,9 @@ void QuicConnection::WriteIfNotBlocked() {
}
bool QuicConnection::ProcessValidatedPacket() {
- if ((peer_ip_changed_ && !FLAGS_quic_allow_ip_migration) ||
- self_ip_changed_ || self_port_changed_) {
- SendConnectionCloseWithDetails(
- QUIC_ERROR_MIGRATING_ADDRESS,
- "Neither IP address migration, nor self port migration are supported.");
+ if (self_ip_changed_ || self_port_changed_) {
+ SendConnectionCloseWithDetails(QUIC_ERROR_MIGRATING_ADDRESS,
+ "Self address migration is not supported.");
return false;
}
@@ -1615,6 +1613,16 @@ bool QuicConnection::WritePacket(QueuedPacket* packet) {
}
bool QuicConnection::WritePacketInner(QueuedPacket* packet) {
+ if (FLAGS_quic_close_connection_out_of_order_sending &&
+ packet->serialized_packet.packet_number <
+ sent_packet_manager_.largest_sent_packet()) {
+ LOG(DFATAL) << "Attempt to write packet:"
+ << packet->serialized_packet.packet_number
+ << " after:" << sent_packet_manager_.largest_sent_packet();
+ SendConnectionCloseWithDetails(QUIC_INTERNAL_ERROR,
+ "Packet written out of order.");
+ return true;
+ }
if (ShouldDiscardPacket(*packet)) {
++stats_.packets_discarded;
return true;
« no previous file with comments | « net/quic/congestion_control/tcp_cubic_sender_test.cc ('k') | net/quic/quic_flags.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698