mirror of https://github.com/cbeuw/Cloak
Prevent nil pointer panic when server response is incorrect under CDN mode
This commit is contained in:
parent
80df86c773
commit
cfbdd9a608
|
|
@ -62,3 +62,10 @@ func (ws *WSOverTLS) Handshake(rawConn net.Conn, authInfo AuthInfo) (sessionKey
|
||||||
|
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
|
func (ws *WSOverTLS) Close() error {
|
||||||
|
if ws.WebSocketConn != nil {
|
||||||
|
return ws.WebSocketConn.Close()
|
||||||
|
}
|
||||||
|
return nil
|
||||||
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue