فهرست منبع

common/singbridge: fix dropped context

Lars Lehtonen 1 سال پیش
والد
کامیت
2fc4b31fcf
1فایلهای تغییر یافته به همراه1 افزوده شده و 1 حذف شده
  1. 1 1
      common/singbridge/dialer.go

+ 1 - 1
common/singbridge/dialer.go

@@ -43,7 +43,7 @@ func NewOutboundDialer(outbound proxy.Outbound, dialer internet.Dialer) *XrayOut
 }
 
 func (d *XrayOutboundDialer) DialContext(ctx context.Context, network string, destination M.Socksaddr) (net.Conn, error) {
-	ctx = session.ContextWithOutbound(context.Background(), &session.Outbound{
+	ctx = session.ContextWithOutbound(ctx, &session.Outbound{
 		Target: ToDestination(destination, ToNetwork(network)),
 	})
 	opts := []pipe.Option{pipe.WithSizeLimit(64 * 1024)}