mirror of
https://github.com/v2ray/v2ray-core.git
synced 2026-11-22 23:13:46 +00:00
refine outbound proxy handler interface
This commit is contained in:
7 files changed
+20
-44
No files matched your search
@@ -18,7 +18,7 @@ type OutboundConnectionHandler struct {
|
||||
ConnOutput io.Writer
|
||||
}
|
||||
|
||||
func (v *OutboundConnectionHandler) Dispatch(destination v2net.Destination, payload *alloc.Buffer, ray ray.OutboundRay) error {
|
||||
func (v *OutboundConnectionHandler) Dispatch(destination v2net.Destination, payload *alloc.Buffer, ray ray.OutboundRay) {
|
||||
input := ray.OutboundInput()
|
||||
output := ray.OutboundOutput()
|
||||
|
||||
@@ -48,8 +48,6 @@ func (v *OutboundConnectionHandler) Dispatch(destination v2net.Destination, payl
|
||||
|
||||
v2io.Pipe(v2reader, output)
|
||||
output.Close()
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
func (v *OutboundConnectionHandler) Create(space app.Space, config interface{}, sendThrough v2net.Address) (proxy.OutboundHandler, error) {
|
||||
|
||||
Reference in new issue
Block a user