mirror of
https://github.com/v2fly/v2ray-core.git
synced 2025-01-02 15:36:41 -05:00
prevent goroutine leak
This commit is contained in:
parent
6fa84624cb
commit
7f277c9bcc
@ -392,6 +392,8 @@ func (this *Connection) Terminate() {
|
|||||||
log.Info("KCP|Connection: Terminating connection to ", this.RemoteAddr())
|
log.Info("KCP|Connection: Terminating connection to ", this.RemoteAddr())
|
||||||
|
|
||||||
this.SetState(StateTerminated)
|
this.SetState(StateTerminated)
|
||||||
|
this.dataInputCond.Broadcast()
|
||||||
|
this.dataOutputCond.Broadcast()
|
||||||
this.writer.Close()
|
this.writer.Close()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user