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

Side by Side Diff: net/quic/core/quic_utils.cc

Issue 2412483004: relnote: Add a new RstStreamErrorCode for resetting streams due to push stream is unclaimed and tim… (Closed)
Patch Set: Created 4 years, 2 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/core/quic_utils.h" 5 #include "net/quic/core/quic_utils.h"
6 6
7 #include <ctype.h> 7 #include <ctype.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include <algorithm> 10 #include <algorithm>
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after
195 RETURN_STRING_LITERAL(QUIC_STREAM_PEER_GOING_AWAY); 195 RETURN_STRING_LITERAL(QUIC_STREAM_PEER_GOING_AWAY);
196 RETURN_STRING_LITERAL(QUIC_STREAM_CANCELLED); 196 RETURN_STRING_LITERAL(QUIC_STREAM_CANCELLED);
197 RETURN_STRING_LITERAL(QUIC_RST_ACKNOWLEDGEMENT); 197 RETURN_STRING_LITERAL(QUIC_RST_ACKNOWLEDGEMENT);
198 RETURN_STRING_LITERAL(QUIC_REFUSED_STREAM); 198 RETURN_STRING_LITERAL(QUIC_REFUSED_STREAM);
199 RETURN_STRING_LITERAL(QUIC_STREAM_LAST_ERROR); 199 RETURN_STRING_LITERAL(QUIC_STREAM_LAST_ERROR);
200 RETURN_STRING_LITERAL(QUIC_INVALID_PROMISE_URL); 200 RETURN_STRING_LITERAL(QUIC_INVALID_PROMISE_URL);
201 RETURN_STRING_LITERAL(QUIC_UNAUTHORIZED_PROMISE_URL); 201 RETURN_STRING_LITERAL(QUIC_UNAUTHORIZED_PROMISE_URL);
202 RETURN_STRING_LITERAL(QUIC_DUPLICATE_PROMISE_URL); 202 RETURN_STRING_LITERAL(QUIC_DUPLICATE_PROMISE_URL);
203 RETURN_STRING_LITERAL(QUIC_PROMISE_VARY_MISMATCH); 203 RETURN_STRING_LITERAL(QUIC_PROMISE_VARY_MISMATCH);
204 RETURN_STRING_LITERAL(QUIC_INVALID_PROMISE_METHOD); 204 RETURN_STRING_LITERAL(QUIC_INVALID_PROMISE_METHOD);
205 RETURN_STRING_LITERAL(QUIC_PUSH_STREAM_TIMED_OUT);
205 } 206 }
206 // Return a default value so that we return this when |error| doesn't match 207 // Return a default value so that we return this when |error| doesn't match
207 // any of the QuicRstStreamErrorCodes. This can happen when the RstStream 208 // any of the QuicRstStreamErrorCodes. This can happen when the RstStream
208 // frame sent by the peer (attacker) has invalid error code. 209 // frame sent by the peer (attacker) has invalid error code.
209 return "INVALID_RST_STREAM_ERROR_CODE"; 210 return "INVALID_RST_STREAM_ERROR_CODE";
210 } 211 }
211 212
212 // static 213 // static
213 const char* QuicUtils::ErrorToString(QuicErrorCode error) { 214 const char* QuicUtils::ErrorToString(QuicErrorCode error) {
214 switch (error) { 215 switch (error) {
(...skipping 353 matching lines...) Expand 10 before | Expand all | Expand 10 after
568 569
569 bytes_remaining -= line_bytes; 570 bytes_remaining -= line_bytes;
570 offset += line_bytes; 571 offset += line_bytes;
571 p += line_bytes; 572 p += line_bytes;
572 s += '\n'; 573 s += '\n';
573 } 574 }
574 return s; 575 return s;
575 } 576 }
576 577
577 } // namespace net 578 } // namespace net
OLDNEW
« net/quic/core/quic_flags_list.h ('K') | « net/quic/core/quic_protocol_test.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698