dont reuse shadowsock connections

pull/314/head
Darien Raymond 8 years ago
parent 68b85cce60
commit c5a92e00ef
No known key found for this signature in database
GPG Key ID: 7251FFA14BB18169

@ -61,6 +61,8 @@ func (this *Client) Dispatch(destination v2net.Destination, payload *alloc.Buffe
}
log.Info("Shadowsocks|Client: Tunneling request to ", destination, " via ", server.Destination())
conn.SetReusable(false)
request := &protocol.RequestHeader{
Version: Version,
Address: destination.Address,

@ -146,6 +146,7 @@ func (this *Server) handlerUDPPayload(payload *alloc.Buffer, session *proxy.Sess
func (this *Server) handleConnection(conn internet.Connection) {
defer conn.Close()
conn.SetReusable(false)
timedReader := v2net.NewTimeOutReader(16, conn)
defer timedReader.Release()

Loading…
Cancel
Save