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

Side by Side Diff: net/quic/quic_connection.cc

Issue 1782193002: Add whether QUIC's unencrypted stream data was received or about to be sent in the error log. Logg… (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@116146641
Patch Set: Created 4 years, 9 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 unified diff | Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/quic/quic_connection.h" 5 #include "net/quic/quic_connection.h"
6 6
7 #include <string.h> 7 #include <string.h>
8 #include <sys/types.h> 8 #include <sys/types.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 637 matching lines...) Expand 10 before | Expand all | Expand 10 after
648 bool QuicConnection::OnStreamFrame(const QuicStreamFrame& frame) { 648 bool QuicConnection::OnStreamFrame(const QuicStreamFrame& frame) {
649 DCHECK(connected_); 649 DCHECK(connected_);
650 if (debug_visitor_ != nullptr) { 650 if (debug_visitor_ != nullptr) {
651 debug_visitor_->OnStreamFrame(frame); 651 debug_visitor_->OnStreamFrame(frame);
652 } 652 }
653 if (frame.stream_id != kCryptoStreamId && 653 if (frame.stream_id != kCryptoStreamId &&
654 last_decrypted_packet_level_ == ENCRYPTION_NONE) { 654 last_decrypted_packet_level_ == ENCRYPTION_NONE) {
655 QUIC_BUG << ENDPOINT 655 QUIC_BUG << ENDPOINT
656 << "Received an unencrypted data frame: closing connection" 656 << "Received an unencrypted data frame: closing connection"
657 << " packet_number:" << last_header_.packet_number 657 << " packet_number:" << last_header_.packet_number
658 << " stream_id:" << frame.stream_id
658 << " received_packets:" << received_packet_manager_.ack_frame(); 659 << " received_packets:" << received_packet_manager_.ack_frame();
659 SendConnectionCloseWithDetails(QUIC_UNENCRYPTED_STREAM_DATA, 660 SendConnectionCloseWithDetails(QUIC_UNENCRYPTED_STREAM_DATA,
660 "Unencrypted stream data seen"); 661 "Unencrypted stream data seen");
661 return false; 662 return false;
662 } 663 }
663 visitor_->OnStreamFrame(frame); 664 visitor_->OnStreamFrame(frame);
664 visitor_->PostProcessAfterData(); 665 visitor_->PostProcessAfterData();
665 stats_.stream_bytes_received += frame.frame_length; 666 stats_.stream_bytes_received += frame.frame_length;
666 should_last_packet_instigate_acks_ = true; 667 should_last_packet_instigate_acks_ = true;
667 return connected_; 668 return connected_;
(...skipping 1665 matching lines...) Expand 10 before | Expand all | Expand 10 after
2333 void QuicConnection::OnPathClosed(QuicPathId path_id) { 2334 void QuicConnection::OnPathClosed(QuicPathId path_id) {
2334 // Stop receiving packets on this path. 2335 // Stop receiving packets on this path.
2335 framer_.OnPathClosed(path_id); 2336 framer_.OnPathClosed(path_id);
2336 } 2337 }
2337 2338
2338 bool QuicConnection::ack_frame_updated() const { 2339 bool QuicConnection::ack_frame_updated() const {
2339 return received_packet_manager_.ack_frame_updated(); 2340 return received_packet_manager_.ack_frame_updated();
2340 } 2341 }
2341 2342
2342 } // namespace net 2343 } // namespace net
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698