| 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/quic/quic_utils.h" | 5 #include "net/quic/quic_utils.h" |
| 6 | 6 |
| 7 #include "base/logging.h" | 7 #include "base/logging.h" |
| 8 #include "base/port.h" | 8 #include "base/port.h" |
| 9 | 9 |
| 10 namespace net { | 10 namespace net { |
| (...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 83 RETURN_STRING_LITERAL(QUIC_INVALID_CRYPTO_MESSAGE_PARAMETER); | 83 RETURN_STRING_LITERAL(QUIC_INVALID_CRYPTO_MESSAGE_PARAMETER); |
| 84 RETURN_STRING_LITERAL(QUIC_CRYPTO_MESSAGE_PARAMETER_NOT_FOUND); | 84 RETURN_STRING_LITERAL(QUIC_CRYPTO_MESSAGE_PARAMETER_NOT_FOUND); |
| 85 RETURN_STRING_LITERAL(QUIC_CRYPTO_MESSAGE_PARAMETER_NO_OVERLAP); | 85 RETURN_STRING_LITERAL(QUIC_CRYPTO_MESSAGE_PARAMETER_NO_OVERLAP); |
| 86 RETURN_STRING_LITERAL(QUIC_CRYPTO_MESSAGE_INDEX_NOT_FOUND); | 86 RETURN_STRING_LITERAL(QUIC_CRYPTO_MESSAGE_INDEX_NOT_FOUND); |
| 87 RETURN_STRING_LITERAL(QUIC_INVALID_STREAM_ID); | 87 RETURN_STRING_LITERAL(QUIC_INVALID_STREAM_ID); |
| 88 RETURN_STRING_LITERAL(QUIC_TOO_MANY_OPEN_STREAMS); | 88 RETURN_STRING_LITERAL(QUIC_TOO_MANY_OPEN_STREAMS); |
| 89 RETURN_STRING_LITERAL(QUIC_PUBLIC_RESET); | 89 RETURN_STRING_LITERAL(QUIC_PUBLIC_RESET); |
| 90 RETURN_STRING_LITERAL(QUIC_INVALID_VERSION); | 90 RETURN_STRING_LITERAL(QUIC_INVALID_VERSION); |
| 91 RETURN_STRING_LITERAL(QUIC_CONNECTION_TIMED_OUT); | 91 RETURN_STRING_LITERAL(QUIC_CONNECTION_TIMED_OUT); |
| 92 RETURN_STRING_LITERAL(QUIC_PROOF_INVALID); | 92 RETURN_STRING_LITERAL(QUIC_PROOF_INVALID); |
| 93 RETURN_STRING_LITERAL(QUIC_CRYPTO_DUPLICATE_TAG); |
| 93 RETURN_STRING_LITERAL(QUIC_LAST_ERROR); | 94 RETURN_STRING_LITERAL(QUIC_LAST_ERROR); |
| 94 // Intentionally have no default case, so we'll break the build | 95 // Intentionally have no default case, so we'll break the build |
| 95 // if we add errors and don't put them here. | 96 // if we add errors and don't put them here. |
| 96 } | 97 } |
| 97 // Return a default value so that we return this when |error| doesn't match | 98 // Return a default value so that we return this when |error| doesn't match |
| 98 // any of the QuicErrorCodes. This can happen when the ConnectionClose | 99 // any of the QuicErrorCodes. This can happen when the ConnectionClose |
| 99 // frame sent by the peer (attacker) has invalid error code. | 100 // frame sent by the peer (attacker) has invalid error code. |
| 100 return "INVALID_ERROR_CODE"; | 101 return "INVALID_ERROR_CODE"; |
| 101 } | 102 } |
| 102 | 103 |
| 103 } // namespace net | 104 } // namespace net |
| OLD | NEW |