mirror of
https://github.com/XTLS/Xray-core.git
synced 2025-06-14 04:19:36 +03:00
Fix: TFO AsIs bug (#452)
This commit is contained in:
@ -17,3 +17,14 @@ func isUDPSocket(network string) bool {
|
||||
return false
|
||||
}
|
||||
}
|
||||
|
||||
func (v *SocketConfig) ParseTFOValue() int {
|
||||
if v.Tfo == 0 {
|
||||
return -1
|
||||
}
|
||||
tfo := int(v.Tfo)
|
||||
if tfo < 0 {
|
||||
tfo = 0
|
||||
}
|
||||
return tfo
|
||||
}
|
||||
|
Reference in New Issue
Block a user