mirror of
https://github.com/v2fly/v2ray-core.git
synced 2024-12-21 17:46:58 -05:00
send request without waiting for the first packet.
This commit is contained in:
parent
86f97616fc
commit
f0c1695db4
@ -176,14 +176,9 @@ func (this *SocksServer) handleSocks5(reader *v2net.TimeOutReader, writer io.Wri
|
||||
}
|
||||
|
||||
dest := request.Destination()
|
||||
data, err := v2net.ReadFrom(reader, nil)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
log.Info("TCP Connect request to %s", dest.String())
|
||||
|
||||
packet := v2net.NewPacket(dest, data, true)
|
||||
packet := v2net.NewPacket(dest, nil, true)
|
||||
this.transport(reader, writer, packet)
|
||||
return nil
|
||||
}
|
||||
@ -242,12 +237,7 @@ func (this *SocksServer) handleSocks4(reader io.Reader, writer io.Writer, auth p
|
||||
}
|
||||
|
||||
dest := v2net.NewTCPDestination(v2net.IPAddress(auth.IP[:], auth.Port))
|
||||
data, err := v2net.ReadFrom(reader, nil)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
packet := v2net.NewPacket(dest, data, true)
|
||||
packet := v2net.NewPacket(dest, nil, true)
|
||||
this.transport(reader, writer, packet)
|
||||
return nil
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user