watchtower/wtserver/server: print connFailure error code name

This commit is contained in:
Conner Fromknecht committed 2019-04-23 20:06:38 -07:00
1 parent ec6e2010d6
commit 590f5811e8
4 files changed
+6 -6

No files matched your search

+2 -2
View File
@@ -283,12 +283,12 @@ func (s *Server) handleClient(peer Peer) {
// error code.
type connFailure struct {
ID wtdb.SessionID
Code uint16
Code wtwire.ErrorCode
}
// Error displays the SessionID and Code that caused the connection failure.
func (f *connFailure) Error() string {
return fmt.Sprintf("connection with %s failed with code=%v",
return fmt.Sprintf("connection with %s failed with code=%s",
f.ID, f.Code,
)
}