Преглед изворни кода

add a default method incase authentcation handshake does something wrong

Chris Bannister пре 10 година
родитељ
комит
5a47bda96f
1 измењених фајлова са 2 додато и 0 уклоњено
  1. 2 0
      conn.go

+ 2 - 0
conn.go

@@ -263,6 +263,8 @@ func (c *Conn) authenticateHandshake(authFrame *authenticateFrame) error {
 			req = &writeAuthResponseFrame{
 				data: resp,
 			}
+		default:
+			return fmt.Errorf("unknown frame response during authentication: %v", v)
 		}
 	}
 }