OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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/quic/quic_dispatcher.h" | 5 #include "net/quic/quic_dispatcher.h" |
6 | 6 |
7 #include <errno.h> | 7 #include <errno.h> |
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 267 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
278 // packets. | 278 // packets. |
279 QuicVersion version = header.versions.front(); | 279 QuicVersion version = header.versions.front(); |
280 time_wait_list_manager_->AddConnectionIdToTimeWait(connection_id, version, | 280 time_wait_list_manager_->AddConnectionIdToTimeWait(connection_id, version, |
281 nullptr); | 281 nullptr); |
282 DCHECK(time_wait_list_manager_->IsConnectionIdInTimeWait(connection_id)); | 282 DCHECK(time_wait_list_manager_->IsConnectionIdInTimeWait(connection_id)); |
283 HandlePacketForTimeWait(header); | 283 HandlePacketForTimeWait(header); |
284 | 284 |
285 return nullptr; | 285 return nullptr; |
286 } | 286 } |
287 | 287 |
288 DVLOG(1) << "Created new session for " << connection_id; | 288 DVLOG(1) << "Created new session for connection ID " << connection_id; |
289 session_map_.insert(std::make_pair(connection_id, session)); | 289 session_map_.insert(std::make_pair(connection_id, session)); |
290 | 290 |
291 return session; | 291 return session; |
292 } | 292 } |
293 | 293 |
294 void QuicDispatcher::OnUnauthenticatedHeader(const QuicPacketHeader& header) { | 294 void QuicDispatcher::OnUnauthenticatedHeader(const QuicPacketHeader& header) { |
295 DCHECK(time_wait_list_manager_->IsConnectionIdInTimeWait( | 295 DCHECK(time_wait_list_manager_->IsConnectionIdInTimeWait( |
296 header.public_header.connection_id)); | 296 header.public_header.connection_id)); |
297 time_wait_list_manager_->ProcessPacket(current_server_address_, | 297 time_wait_list_manager_->ProcessPacket(current_server_address_, |
298 current_client_address_, | 298 current_client_address_, |
(...skipping 119 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
418 // be parsed correctly. | 418 // be parsed correctly. |
419 framer_.set_version(time_wait_list_manager_->GetQuicVersionFromConnectionId( | 419 framer_.set_version(time_wait_list_manager_->GetQuicVersionFromConnectionId( |
420 header.connection_id)); | 420 header.connection_id)); |
421 | 421 |
422 // Continue parsing the packet to extract the sequence number. Then | 422 // Continue parsing the packet to extract the sequence number. Then |
423 // send it to the time wait manager in OnUnathenticatedHeader. | 423 // send it to the time wait manager in OnUnathenticatedHeader. |
424 return true; | 424 return true; |
425 } | 425 } |
426 | 426 |
427 } // namespace net | 427 } // namespace net |
OLD | NEW |