浏览代码

Merge branch 'master' of https://github.com/v2ray/v2ray-core

v2ray 10 年之前
父节点
当前提交
f3f1c09e49
共有 2 个文件被更改,包括 5 次插入0 次删除
  1. 2 0
      shell/point/inbound_detour.go
  2. 3 0
      shell/point/point.go

+ 2 - 0
shell/point/inbound_detour.go

@@ -13,6 +13,7 @@ type InboundConnectionHandlerWithPort struct {
 	handler connhandler.InboundConnectionHandler
 }
 
+// Handler for inbound detour connections.
 type InboundDetourHandler struct {
 	point  *Point
 	config config.InboundDetourConfig
@@ -43,6 +44,7 @@ func (this *InboundDetourHandler) Initialize() error {
 	return nil
 }
 
+// Starts the inbound connection handler.
 func (this *InboundDetourHandler) Start() error {
 	for _, ich := range this.ich {
 		return retry.Timed(100 /* times */, 100 /* ms */).On(func() error {

+ 3 - 0
shell/point/point.go

@@ -129,6 +129,9 @@ func (this *Point) Start() error {
 	return nil
 }
 
+// Dispatches a Packet to an OutboundConnection.
+// The packet will be passed through the router (if configured), and then sent to an outbound
+// connection with matching tag.
 func (this *Point) DispatchToOutbound(packet v2net.Packet) ray.InboundRay {
 	direct := ray.NewRay()
 	dest := packet.Destination()