mirror of
https://github.com/v2fly/v2ray-core.git
synced 2025-01-05 00:47:51 -05:00
notify progressTraffic to quit
This commit is contained in:
parent
3e05a3529a
commit
09bf78a089
@ -39,8 +39,12 @@ func (uih *UnixInboundHandler) Start() {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
func (uih *UnixInboundHandler) progressTraffic(rece <-chan net.Conn) {
|
func (uih *UnixInboundHandler) progressTraffic(rece <-chan net.Conn) {
|
||||||
|
|
||||||
for {
|
for {
|
||||||
conn := <-rece
|
conn, notclosed := <-rece
|
||||||
|
if !notclosed {
|
||||||
|
return
|
||||||
|
}
|
||||||
go func(conn net.Conn) {
|
go func(conn net.Conn) {
|
||||||
ctx, cancel := context.WithCancel(uih.ctx)
|
ctx, cancel := context.WithCancel(uih.ctx)
|
||||||
if len(uih.tag) > 0 {
|
if len(uih.tag) > 0 {
|
||||||
|
@ -128,6 +128,7 @@ func (ls *Listener) uploop(cctx context.Context) {
|
|||||||
errortolerance := 5
|
errortolerance := 5
|
||||||
for {
|
for {
|
||||||
if cctx.Err() != nil {
|
if cctx.Err() != nil {
|
||||||
|
close(ls.listenerChan)
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
conn, err := ls.ln.Accept()
|
conn, err := ls.ln.Accept()
|
||||||
|
Loading…
Reference in New Issue
Block a user