mirror of
https://github.com/v2fly/v2ray-core.git
synced 2024-11-18 18:36:11 -05:00
Leverage v2net functions
This commit is contained in:
parent
798011b140
commit
aa4d897a21
@ -172,11 +172,9 @@ func handleResponse(conn net.Conn, request *protocol.VMessRequest, output chan<-
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
buffer := make([]byte, 2*1024)
|
buffer, err := v2net.ReadFrom(decryptResponseReader)
|
||||||
|
|
||||||
nBytes, err := decryptResponseReader.Read(buffer)
|
|
||||||
if err != nil {
|
if err != nil {
|
||||||
//log.Error("VMessOut: Failed to read VMess response (%d bytes): %v", nBytes, err)
|
log.Error("VMessOut: Failed to read VMess response (%d bytes): %v", nBytes, err)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
if !bytes.Equal(buffer[:4], request.ResponseHeader[:]) {
|
if !bytes.Equal(buffer[:4], request.ResponseHeader[:]) {
|
||||||
|
Loading…
Reference in New Issue
Block a user