diff --git a/deps/easy/src/io/easy_negotiation.c b/deps/easy/src/io/easy_negotiation.c index 4efa4b85f..389ac1ca8 100644 --- a/deps/easy/src/io/easy_negotiation.c +++ b/deps/easy/src/io/easy_negotiation.c @@ -82,9 +82,9 @@ static int easy_decode_uint64(char *buf, const int64_t data_len, int64_t *pos, u *val |= (((uint64_t)((*(buf + (*pos)++))) & 0xff)) << 48; *val |= (((uint64_t)((*(buf + (*pos)++))) & 0xff)) << 40; *val |= (((uint64_t)((*(buf + (*pos)++))) & 0xff)) << 32; - *val |= (((uint64_t)((*(buf + (*pos)++))) & 0xff)) << 24; - *val |= (((uint64_t)((*(buf + (*pos)++))) & 0xff)) << 16; - *val |= (((uint64_t)((*(buf + (*pos)++))) & 0xff)) << 8; + *val |= (((uint64_t)((*(buf + (*pos)++))) & 0xff)) << 24; + *val |= (((uint64_t)((*(buf + (*pos)++))) & 0xff)) << 16; + *val |= (((uint64_t)((*(buf + (*pos)++))) & 0xff)) << 8; *val |= (((uint64_t)((*(buf + (*pos)++))) & 0xff)); } @@ -146,9 +146,9 @@ static int easy_decode_negotiation_msg(easy_negotiation_msg_t *ne_msg, char *rec easy_error_log("easy_decode_negotiation_msg, invalid param!"); return EASY_ERROR; } - - ret = easy_decode_uint64(recv_buf, recv_buf_len, &pos, &(ne_msg->msg_header.header_magic)); - if (ret != EASY_OK) { + + ret = easy_decode_uint64(recv_buf, recv_buf_len, &pos, &(ne_msg->msg_header.header_magic)); + if (ret != EASY_OK) { easy_info_log("easy decode header magic failed!ret:%d.", ret); return ret; } @@ -294,9 +294,9 @@ int easy_send_negotiate_message(easy_connection_t *c) c->conn_has_error = conn_has_error; } return ret; -} - -void easy_consume_negotiation_msg(int fd, easy_io_t *eio) +} + +void easy_consume_negotiation_msg(int fd, easy_io_t *eio) { net_consume_negotiation_msg(fd, eio->magic); }