| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 #include "net/tools/quic/quic_dispatcher.h" | 5 #include "net/tools/quic/quic_dispatcher.h" |
| 6 | 6 |
| 7 #include <utility> | 7 #include <utility> |
| 8 | 8 |
| 9 #include "base/debug/stack_trace.h" | 9 #include "base/debug/stack_trace.h" |
| 10 #include "base/logging.h" | 10 #include "base/logging.h" |
| (...skipping 531 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 542 bool QuicDispatcher::ShouldCreateSessionForUnknownVersion(QuicTag version_tag) { | 542 bool QuicDispatcher::ShouldCreateSessionForUnknownVersion(QuicTag version_tag) { |
| 543 return false; | 543 return false; |
| 544 } | 544 } |
| 545 | 545 |
| 546 bool QuicDispatcher::OnProtocolVersionMismatch( | 546 bool QuicDispatcher::OnProtocolVersionMismatch( |
| 547 QuicVersion /*received_version*/) { | 547 QuicVersion /*received_version*/) { |
| 548 QUIC_BUG_IF(!time_wait_list_manager_->IsConnectionIdInTimeWait( | 548 QUIC_BUG_IF(!time_wait_list_manager_->IsConnectionIdInTimeWait( |
| 549 current_connection_id_) && | 549 current_connection_id_) && |
| 550 !ShouldCreateSessionForUnknownVersion(framer_.last_version_tag())) | 550 !ShouldCreateSessionForUnknownVersion(framer_.last_version_tag())) |
| 551 << "Unexpected version mismatch: " | 551 << "Unexpected version mismatch: " |
| 552 << QuicUtils::TagToString(framer_.last_version_tag()); | 552 << QuicTagToString(framer_.last_version_tag()); |
| 553 | 553 |
| 554 // Keep processing after protocol mismatch - this will be dealt with by the | 554 // Keep processing after protocol mismatch - this will be dealt with by the |
| 555 // time wait list or connection that we will create. | 555 // time wait list or connection that we will create. |
| 556 return true; | 556 return true; |
| 557 } | 557 } |
| 558 | 558 |
| 559 void QuicDispatcher::OnPublicResetPacket( | 559 void QuicDispatcher::OnPublicResetPacket( |
| 560 const QuicPublicResetPacket& /*packet*/) { | 560 const QuicPublicResetPacket& /*packet*/) { |
| 561 DCHECK(false); | 561 DCHECK(false); |
| 562 } | 562 } |
| (...skipping 422 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 985 void QuicDispatcher::DeliverPacketsToSession( | 985 void QuicDispatcher::DeliverPacketsToSession( |
| 986 const std::list<BufferedPacket>& packets, | 986 const std::list<BufferedPacket>& packets, |
| 987 QuicSession* session) { | 987 QuicSession* session) { |
| 988 for (const BufferedPacket& packet : packets) { | 988 for (const BufferedPacket& packet : packets) { |
| 989 session->ProcessUdpPacket(packet.server_address, packet.client_address, | 989 session->ProcessUdpPacket(packet.server_address, packet.client_address, |
| 990 *(packet.packet)); | 990 *(packet.packet)); |
| 991 } | 991 } |
| 992 } | 992 } |
| 993 | 993 |
| 994 } // namespace net | 994 } // namespace net |
| OLD | NEW |