mirror of
https://github.com/refraction-networking/uquic.git
synced 2025-04-04 20:57:36 +03:00
ackhandler: remove unused version parameter from constructor
This commit is contained in:
parent
576d85cd3d
commit
3affa1d911
6 changed files with 5 additions and 14 deletions
|
@ -296,7 +296,6 @@ var newConnection = func(
|
||||||
s.perspective,
|
s.perspective,
|
||||||
s.tracer,
|
s.tracer,
|
||||||
s.logger,
|
s.logger,
|
||||||
s.version,
|
|
||||||
)
|
)
|
||||||
initialStream := newCryptoStream()
|
initialStream := newCryptoStream()
|
||||||
handshakeStream := newCryptoStream()
|
handshakeStream := newCryptoStream()
|
||||||
|
@ -431,7 +430,6 @@ var newClientConnection = func(
|
||||||
s.perspective,
|
s.perspective,
|
||||||
s.tracer,
|
s.tracer,
|
||||||
s.logger,
|
s.logger,
|
||||||
s.version,
|
|
||||||
)
|
)
|
||||||
initialStream := newCryptoStream()
|
initialStream := newCryptoStream()
|
||||||
handshakeStream := newCryptoStream()
|
handshakeStream := newCryptoStream()
|
||||||
|
|
|
@ -17,8 +17,7 @@ func NewAckHandler(
|
||||||
pers protocol.Perspective,
|
pers protocol.Perspective,
|
||||||
tracer logging.ConnectionTracer,
|
tracer logging.ConnectionTracer,
|
||||||
logger utils.Logger,
|
logger utils.Logger,
|
||||||
version protocol.VersionNumber,
|
|
||||||
) (SentPacketHandler, ReceivedPacketHandler) {
|
) (SentPacketHandler, ReceivedPacketHandler) {
|
||||||
sph := newSentPacketHandler(initialPacketNumber, initialMaxDatagramSize, rttStats, clientAddressValidated, pers, tracer, logger)
|
sph := newSentPacketHandler(initialPacketNumber, initialMaxDatagramSize, rttStats, clientAddressValidated, pers, tracer, logger)
|
||||||
return sph, newReceivedPacketHandler(sph, rttStats, logger, version)
|
return sph, newReceivedPacketHandler(sph, rttStats, logger)
|
||||||
}
|
}
|
||||||
|
|
|
@ -25,13 +25,12 @@ func newReceivedPacketHandler(
|
||||||
sentPackets sentPacketTracker,
|
sentPackets sentPacketTracker,
|
||||||
rttStats *utils.RTTStats,
|
rttStats *utils.RTTStats,
|
||||||
logger utils.Logger,
|
logger utils.Logger,
|
||||||
version protocol.VersionNumber,
|
|
||||||
) ReceivedPacketHandler {
|
) ReceivedPacketHandler {
|
||||||
return &receivedPacketHandler{
|
return &receivedPacketHandler{
|
||||||
sentPackets: sentPackets,
|
sentPackets: sentPackets,
|
||||||
initialPackets: newReceivedPacketTracker(rttStats, logger, version),
|
initialPackets: newReceivedPacketTracker(rttStats, logger),
|
||||||
handshakePackets: newReceivedPacketTracker(rttStats, logger, version),
|
handshakePackets: newReceivedPacketTracker(rttStats, logger),
|
||||||
appDataPackets: newReceivedPacketTracker(rttStats, logger, version),
|
appDataPackets: newReceivedPacketTracker(rttStats, logger),
|
||||||
lowest1RTTPacket: protocol.InvalidPacketNumber,
|
lowest1RTTPacket: protocol.InvalidPacketNumber,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -23,7 +23,6 @@ var _ = Describe("Received Packet Handler", func() {
|
||||||
sentPackets,
|
sentPackets,
|
||||||
&utils.RTTStats{},
|
&utils.RTTStats{},
|
||||||
utils.DefaultLogger,
|
utils.DefaultLogger,
|
||||||
protocol.VersionWhatever,
|
|
||||||
)
|
)
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
|
@ -31,21 +31,17 @@ type receivedPacketTracker struct {
|
||||||
lastAck *wire.AckFrame
|
lastAck *wire.AckFrame
|
||||||
|
|
||||||
logger utils.Logger
|
logger utils.Logger
|
||||||
|
|
||||||
version protocol.VersionNumber
|
|
||||||
}
|
}
|
||||||
|
|
||||||
func newReceivedPacketTracker(
|
func newReceivedPacketTracker(
|
||||||
rttStats *utils.RTTStats,
|
rttStats *utils.RTTStats,
|
||||||
logger utils.Logger,
|
logger utils.Logger,
|
||||||
version protocol.VersionNumber,
|
|
||||||
) *receivedPacketTracker {
|
) *receivedPacketTracker {
|
||||||
return &receivedPacketTracker{
|
return &receivedPacketTracker{
|
||||||
packetHistory: newReceivedPacketHistory(),
|
packetHistory: newReceivedPacketHistory(),
|
||||||
maxAckDelay: protocol.MaxAckDelay,
|
maxAckDelay: protocol.MaxAckDelay,
|
||||||
rttStats: rttStats,
|
rttStats: rttStats,
|
||||||
logger: logger,
|
logger: logger,
|
||||||
version: version,
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -19,7 +19,7 @@ var _ = Describe("Received Packet Tracker", func() {
|
||||||
|
|
||||||
BeforeEach(func() {
|
BeforeEach(func() {
|
||||||
rttStats = &utils.RTTStats{}
|
rttStats = &utils.RTTStats{}
|
||||||
tracker = newReceivedPacketTracker(rttStats, utils.DefaultLogger, protocol.VersionWhatever)
|
tracker = newReceivedPacketTracker(rttStats, utils.DefaultLogger)
|
||||||
})
|
})
|
||||||
|
|
||||||
Context("accepting packets", func() {
|
Context("accepting packets", func() {
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue