0

Websocket client errors as Warns, broken pipe errors as Trace (#656)

* Websocket client errors now logged as Warns
broken pipe errors now logged as Trace

* additional space for broken pipe logs
This commit is contained in:
petersveter108 2021-01-22 22:50:23 +01:00 committed by GitHub
parent 1fef9cf045
commit 401995c52e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -115,7 +115,7 @@ func (c *Client) listenWrite() {
} }
func (c *Client) handleClientSocketError(err error) { func (c *Client) handleClientSocketError(err error) {
log.Errorln("Websocket client error: ", err.Error()) log.Warnln("Websocket client error: ", err.Error())
_server.removeClient(c) _server.removeClient(c)
} }

View File

@ -126,7 +126,7 @@ func (s *server) Listen() {
fmt.Println("PING?", ping) fmt.Println("PING?", ping)
case err := <-s.errCh: case err := <-s.errCh:
log.Error("Error:", err.Error()) log.Trace("Error: ", err.Error())
case <-s.doneCh: case <-s.doneCh:
return return