forked from quic-go/quic-go
use the CRYPTO_BUFFER_EXCEEDED error for crypto stream overflows
This commit is contained in:
@@ -23,6 +23,7 @@ const (
|
||||
VersionNegotiationError ErrorCode = 0x9
|
||||
ProtocolViolation ErrorCode = 0xa
|
||||
InvalidMigration ErrorCode = 0xc
|
||||
CryptoBufferExceeded ErrorCode = 0xd
|
||||
)
|
||||
|
||||
func (e ErrorCode) isCryptoError() bool {
|
||||
@@ -71,6 +72,8 @@ func (e ErrorCode) String() string {
|
||||
return "PROTOCOL_VIOLATION"
|
||||
case InvalidMigration:
|
||||
return "INVALID_MIGRATION"
|
||||
case CryptoBufferExceeded:
|
||||
return "CRYPTO_BUFFER_EXCEEDED"
|
||||
default:
|
||||
if e.isCryptoError() {
|
||||
return "CRYPTO_ERROR"
|
||||
|
||||
Reference in New Issue
Block a user