Skip to content

Commit

Permalink
f
Browse files Browse the repository at this point in the history
  • Loading branch information
wujunzhuo committed Aug 17, 2022
1 parent 80f8536 commit 9e3ef07
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions core/client.go
Expand Up @@ -117,14 +117,13 @@ func (c *Client) connect(ctx context.Context, addr string) error {
c.opts.Credential.Name(),
c.opts.Credential.Payload(),
)
_, err = c.fs.WriteFrame(handshake)
if err != nil {
if _, err := c.fs.WriteFrame(handshake); err != nil {
c.state = ConnStateDisconnected
return err
}

c.state = ConnStateConnected
c.localAddr = conn.LocalAddr().String()
c.localAddr = c.conn.LocalAddr().String()

c.logger.Printf("%s鉂わ笍 [%s][%s](%s) is connected to YoMo-Zipper %s", ClientLogPrefix, c.name, c.clientID, c.localAddr, addr)

Expand Down

0 comments on commit 9e3ef07

Please sign in to comment.