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

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

Issue 1565883003: relnote: Moving many QUIC DFATALS over to QUIC_BUG (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: add unused flag to keep code consistent Created 4 years, 11 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
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>
11 #include <iterator> 11 #include <iterator>
12 #include <limits> 12 #include <limits>
13 #include <memory> 13 #include <memory>
14 #include <set> 14 #include <set>
15 #include <utility> 15 #include <utility>
16 16
17 #include "base/format_macros.h" 17 #include "base/format_macros.h"
18 #include "base/logging.h" 18 #include "base/logging.h"
19 #include "base/macros.h" 19 #include "base/macros.h"
20 #include "base/memory/ref_counted.h" 20 #include "base/memory/ref_counted.h"
21 #include "base/stl_util.h" 21 #include "base/stl_util.h"
22 #include "base/strings/stringprintf.h" 22 #include "base/strings/stringprintf.h"
23 #include "net/base/net_errors.h" 23 #include "net/base/net_errors.h"
24 #include "net/quic/crypto/crypto_protocol.h" 24 #include "net/quic/crypto/crypto_protocol.h"
25 #include "net/quic/crypto/quic_decrypter.h" 25 #include "net/quic/crypto/quic_decrypter.h"
26 #include "net/quic/crypto/quic_encrypter.h" 26 #include "net/quic/crypto/quic_encrypter.h"
27 #include "net/quic/proto/cached_network_parameters.pb.h" 27 #include "net/quic/proto/cached_network_parameters.pb.h"
28 #include "net/quic/quic_bandwidth.h" 28 #include "net/quic/quic_bandwidth.h"
29 #include "net/quic/quic_bug_tracker.h"
29 #include "net/quic/quic_config.h" 30 #include "net/quic/quic_config.h"
30 #include "net/quic/quic_fec_group.h" 31 #include "net/quic/quic_fec_group.h"
31 #include "net/quic/quic_flags.h" 32 #include "net/quic/quic_flags.h"
32 #include "net/quic/quic_packet_generator.h" 33 #include "net/quic/quic_packet_generator.h"
33 #include "net/quic/quic_utils.h" 34 #include "net/quic/quic_utils.h"
34 35
35 using base::StringPiece; 36 using base::StringPiece;
36 using base::StringPrintf; 37 using base::StringPrintf;
37 using base::hash_map; 38 using base::hash_map;
38 using base::hash_set; 39 using base::hash_set;
(...skipping 1072 matching lines...) Expand 10 before | Expand all | Expand 10 after
1111 } 1112 }
1112 1113
1113 QuicConsumedData QuicConnection::SendStreamData( 1114 QuicConsumedData QuicConnection::SendStreamData(
1114 QuicStreamId id, 1115 QuicStreamId id,
1115 QuicIOVector iov, 1116 QuicIOVector iov,
1116 QuicStreamOffset offset, 1117 QuicStreamOffset offset,
1117 bool fin, 1118 bool fin,
1118 FecProtection fec_protection, 1119 FecProtection fec_protection,
1119 QuicAckListenerInterface* listener) { 1120 QuicAckListenerInterface* listener) {
1120 if (!fin && iov.total_length == 0) { 1121 if (!fin && iov.total_length == 0) {
1121 LOG(DFATAL) << "Attempt to send empty stream frame"; 1122 QUIC_BUG << "Attempt to send empty stream frame";
1122 return QuicConsumedData(0, false); 1123 return QuicConsumedData(0, false);
1123 } 1124 }
1124 1125
1125 // Opportunistically bundle an ack with every outgoing packet. 1126 // Opportunistically bundle an ack with every outgoing packet.
1126 // Particularly, we want to bundle with handshake packets since we don't know 1127 // Particularly, we want to bundle with handshake packets since we don't know
1127 // which decrypter will be used on an ack packet following a handshake 1128 // which decrypter will be used on an ack packet following a handshake
1128 // packet (a handshake packet from client to server could result in a REJ or a 1129 // packet (a handshake packet from client to server could result in a REJ or a
1129 // SHLO from the server, leading to two different decrypters at the server.) 1130 // SHLO from the server, leading to two different decrypters at the server.)
1130 // 1131 //
1131 // TODO(jri): Note that ConsumeData may cause a response packet to be sent. 1132 // TODO(jri): Note that ConsumeData may cause a response packet to be sent.
(...skipping 1285 matching lines...) Expand 10 before | Expand all | Expand 10 after
2417 SendMtuDiscoveryPacket(mtu_discovery_target_); 2418 SendMtuDiscoveryPacket(mtu_discovery_target_);
2418 2419
2419 DCHECK(!mtu_discovery_alarm_->IsSet()); 2420 DCHECK(!mtu_discovery_alarm_->IsSet());
2420 } 2421 }
2421 2422
2422 bool QuicConnection::ack_frame_updated() const { 2423 bool QuicConnection::ack_frame_updated() const {
2423 return received_packet_manager_.ack_frame_updated(); 2424 return received_packet_manager_.ack_frame_updated();
2424 } 2425 }
2425 2426
2426 } // namespace net 2427 } // namespace net
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698