1
0
mirror of https://github.com/v2fly/v2ray-core.git synced 2024-10-01 00:06:11 -04:00

fix locking in vmess inbound

This commit is contained in:
v2ray 2016-01-22 16:50:31 +01:00
parent d8f29f4b5e
commit 795681c288

View File

@ -38,8 +38,8 @@ func (this *VMessInboundHandler) Port() v2net.Port {
func (this *VMessInboundHandler) Close() { func (this *VMessInboundHandler) Close() {
this.accepting = false this.accepting = false
if this.listener != nil { if this.listener != nil {
this.listener.Close()
this.Lock() this.Lock()
this.listener.Close()
this.listener = nil this.listener = nil
this.Unlock() this.Unlock()
} }