Print recovered panic error

This commit is contained in:
Andrew Gutekanst
2020-01-23 20:15:56 -05:00
parent b1b4f390f0
commit 1afe6860e2

View File

@@ -116,7 +116,7 @@ func (s *Session) handlePacketGroup(pktGroup []byte) {
// This shouldn't be needed, but it's better to recover and let the connection die than to panic the server.
defer func() {
if r := recover(); r != nil {
fmt.Println("Recovered from panic.")
fmt.Println("Recovered from panic ", r)
}
}()