forked from quic-go/quic-go
fix several linter warnings and misspellings
This commit is contained in:
@@ -188,7 +188,7 @@ func ParseAckFrame(r *bytes.Reader) (*AckFrame, error) {
|
||||
}
|
||||
|
||||
// Invalid NACK Handling:
|
||||
// NACKs contain a lot of offsets that require substractions of PacketNumbers. If an ACK contains invalid data, it is possible to underflow the uint64 used to store the PacketNumber
|
||||
// NACKs contain a lot of offsets that require subtractions of PacketNumbers. If an ACK contains invalid data, it is possible to underflow the uint64 used to store the PacketNumber
|
||||
// TODO: handle uint64 overflows
|
||||
if hasNACK {
|
||||
var numRanges uint8
|
||||
|
||||
@@ -13,7 +13,7 @@ func (n *NackRange) Len() uint64 {
|
||||
return uint64(n.LastPacketNumber) - uint64(n.FirstPacketNumber)
|
||||
}
|
||||
|
||||
// IsInRange checks if a packetNumber is contained in a NACK range
|
||||
// ContainsPacketNumber checks if a packetNumber is contained in a NACK range
|
||||
func (n *NackRange) ContainsPacketNumber(packetNumber protocol.PacketNumber) bool {
|
||||
if packetNumber >= n.FirstPacketNumber && packetNumber <= n.LastPacketNumber {
|
||||
return true
|
||||
|
||||
Reference in New Issue
Block a user