mirror of
https://github.com/refraction-networking/uquic.git
synced 2025-04-05 13:17:36 +03:00
only enable 0-RTT when using ListenEarly and DialEarly
This commit is contained in:
parent
39efdfe695
commit
eeba3951ae
7 changed files with 57 additions and 30 deletions
|
@ -202,6 +202,7 @@ var newSession = func(
|
|||
conf *Config,
|
||||
tlsConf *tls.Config,
|
||||
tokenGenerator *handshake.TokenGenerator,
|
||||
enable0RTT bool,
|
||||
logger utils.Logger,
|
||||
v protocol.VersionNumber,
|
||||
) quicSession {
|
||||
|
@ -274,7 +275,7 @@ var newSession = func(
|
|||
},
|
||||
},
|
||||
tlsConf,
|
||||
true, // TODO: make 0-RTT support configurable
|
||||
enable0RTT,
|
||||
s.rttStats,
|
||||
logger,
|
||||
)
|
||||
|
@ -308,6 +309,7 @@ var newClientSession = func(
|
|||
tlsConf *tls.Config,
|
||||
initialPacketNumber protocol.PacketNumber,
|
||||
initialVersion protocol.VersionNumber,
|
||||
enable0RTT bool,
|
||||
logger utils.Logger,
|
||||
v protocol.VersionNumber,
|
||||
) quicSession {
|
||||
|
@ -371,7 +373,7 @@ var newClientSession = func(
|
|||
onHandshakeComplete: func() { close(s.handshakeCompleteChan) },
|
||||
},
|
||||
tlsConf,
|
||||
true, // TODO: make 0-RTT support configurable
|
||||
enable0RTT,
|
||||
s.rttStats,
|
||||
logger,
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue