mirror of
https://github.com/v2fly/v2ray-core.git
synced 2026-07-30 11:40:53 -04:00
fix #185
This commit is contained in:
@@ -14,7 +14,11 @@ import (
|
||||
const SO_ORIGINAL_DST = 80
|
||||
|
||||
func GetOriginalDestination(conn internet.Connection) v2net.Destination {
|
||||
tcpConn := conn.(*tcp.Connection)
|
||||
tcpConn, ok := conn.(internet.SysFd)
|
||||
if !ok {
|
||||
log.Info("Dokodemo: Failed to get sys fd.")
|
||||
return nil
|
||||
}
|
||||
fd, err := tcpConn.SysFd()
|
||||
if err != nil {
|
||||
log.Info("Dokodemo: Failed to get original destination: ", err)
|
||||
|
||||
Reference in New Issue
Block a user