mirror of
https://github.com/FrankerFaceZ/FrankerFaceZ.git
synced 2025-06-27 21:05:53 +00:00
reject pongs for non-set-up clients
This commit is contained in:
parent
d254435173
commit
fd357ae6f2
1 changed files with 3 additions and 1 deletions
|
@ -336,7 +336,9 @@ func RunSocketConnection(conn *websocket.Conn) {
|
|||
|
||||
conn.SetPongHandler(func(pongBody string) error {
|
||||
client.Mutex.Lock()
|
||||
if client.HelloOK { // do not accept PONGs until hello sent
|
||||
client.pingCount = 0
|
||||
}
|
||||
client.Mutex.Unlock()
|
||||
return nil
|
||||
})
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue