don't use the wire encoding for the PacketType constant

This commit is contained in:
Marten Seemann
2018-11-26 12:22:50 +07:00
parent dd81dfdbdd
commit 53aeb7d592
5 changed files with 47 additions and 24 deletions

View File

@@ -26,13 +26,13 @@ type PacketType uint8
const (
// PacketTypeInitial is the packet type of an Initial packet
PacketTypeInitial PacketType = 0x7f
PacketTypeInitial PacketType = 1 + iota
// PacketTypeRetry is the packet type of a Retry packet
PacketTypeRetry PacketType = 0x7e
PacketTypeRetry
// PacketTypeHandshake is the packet type of a Handshake packet
PacketTypeHandshake PacketType = 0x7d
PacketTypeHandshake
// PacketType0RTT is the packet type of a 0-RTT packet
PacketType0RTT PacketType = 0x7c
PacketType0RTT
)
func (t PacketType) String() string {