Fix naive HTTP/2 connections

This commit is contained in:
H-TTTTT
2026-07-21 14:29:32 +08:00
committed by 世界
parent d72f0ec1c7
commit 3c4a5a6ed3

View File

@@ -221,7 +221,7 @@ func (n *Inbound) newConnection(ctx context.Context, waitForClose bool, conn net
} else { } else {
done := make(chan struct{}) done := make(chan struct{})
wrapper := v2rayhttp.NewHTTP2Wrapper(conn) wrapper := v2rayhttp.NewHTTP2Wrapper(conn)
n.router.RouteConnectionEx(ctx, conn, metadata, N.OnceClose(func(it error) { n.router.RouteConnectionEx(ctx, wrapper, metadata, N.OnceClose(func(it error) {
close(done) close(done)
})) }))
<-done <-done