Merge pull request #179 from maxsupermanhd/patch-1
Don't send empty host string in handshake
This commit is contained in:
@ -41,6 +41,7 @@ func (c *Client) join(ctx context.Context, d *mcnet.Dialer, addr string) error {
|
||||
var addrErr *net.AddrError
|
||||
const missingPort = "missing port in address"
|
||||
if errors.As(err, &addrErr) && addrErr.Err == missingPort {
|
||||
host = addr
|
||||
port = 25565
|
||||
} else {
|
||||
return LoginErr{"split address", err}
|
||||
|
Reference in New Issue
Block a user