feat: tuic outbound allow set an empty ALPN
array
This commit is contained in:
@ -162,7 +162,7 @@ func NewTuic(option TuicOption) (*Tuic, error) {
|
||||
tlsConfig = tlsC.GetGlobalTLSConfig(tlsConfig)
|
||||
}
|
||||
|
||||
if len(option.ALPN) > 0 {
|
||||
if option.ALPN != nil { // structure's Decode will ensure value not nil when input has value even it was set an empty array
|
||||
tlsConfig.NextProtos = option.ALPN
|
||||
} else {
|
||||
tlsConfig.NextProtos = []string{"h3"}
|
||||
|
Reference in New Issue
Block a user