forked from quic-go/quic-go
fix compatibility with API breaking change in Go 1.21 (#4020)
* add Go 1.21 compatibility Signed-off-by: Eric Lagergren <elagergren@spideroak-inc.com> * refactor for Go 1.20 Signed-off-by: Eric Lagergren <elagergren@spideroak-inc.com> --------- Signed-off-by: Eric Lagergren <elagergren@spideroak-inc.com>
This commit is contained in:
committed by
GitHub
parent
aab4d4e410
commit
571d3adef4
@@ -139,3 +139,7 @@ func SetCipherSuite(id uint16) (reset func()) {
|
||||
cipherSuitesModified = false
|
||||
}
|
||||
}
|
||||
|
||||
func SendSessionTicket(c *QUICConn, allow0RTT bool) error {
|
||||
return c.SendSessionTicket(allow0RTT)
|
||||
}
|
||||
|
||||
@@ -11,12 +11,13 @@ import (
|
||||
)
|
||||
|
||||
type (
|
||||
QUICConn = tls.QUICConn
|
||||
QUICConfig = tls.QUICConfig
|
||||
QUICEvent = tls.QUICEvent
|
||||
QUICEventKind = tls.QUICEventKind
|
||||
QUICEncryptionLevel = tls.QUICEncryptionLevel
|
||||
AlertError = tls.AlertError
|
||||
QUICConn = tls.QUICConn
|
||||
QUICConfig = tls.QUICConfig
|
||||
QUICEvent = tls.QUICEvent
|
||||
QUICEventKind = tls.QUICEventKind
|
||||
QUICEncryptionLevel = tls.QUICEncryptionLevel
|
||||
QUICSessionTicketOptions = tls.QUICSessionTicketOptions
|
||||
AlertError = tls.AlertError
|
||||
)
|
||||
|
||||
const (
|
||||
@@ -152,3 +153,9 @@ func findExtraData(extras [][]byte) []byte {
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func SendSessionTicket(c *QUICConn, allow0RTT bool) error {
|
||||
return c.SendSessionTicket(tls.QUICSessionTicketOptions{
|
||||
EarlyData: allow0RTT,
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user