上次提交的问题修改成功 mph->set_mpb_size(request->ByteSizeLong());
This commit is contained in:
@@ -63,9 +63,6 @@ void management::read_packet(bufferevent *bev, sockaddr_in *addr) {
|
||||
memset(packet_h, 0, sizeof(packet_h));
|
||||
memset(packet_b, 0, sizeof(packet_b));
|
||||
|
||||
std::cout << len_index << std::endl;
|
||||
std::cout << buff << std::endl;
|
||||
|
||||
/// read L 读包长度
|
||||
uint8_t packetLen;
|
||||
// 取包长度
|
||||
@@ -95,8 +92,6 @@ void management::read_packet(bufferevent *bev, sockaddr_in *addr) {
|
||||
// 更新buffer长度
|
||||
len_index -= mph->mpb_size();
|
||||
|
||||
std::cout << buff << std::endl;
|
||||
|
||||
// 请求
|
||||
auto request = analysis(mph, packet_b)(bev, addr);
|
||||
// 响应
|
||||
|
||||
@@ -5,9 +5,6 @@
|
||||
#include "UserProveController.h"
|
||||
|
||||
void UserProveController::run(std::shared_ptr<agreement_request> request, std::shared_ptr<agreement_response> response) {
|
||||
printf("客户端版本:%f", request->m_cqi.cqi_version());
|
||||
printf("account:%s", request->m_body.account().c_str());
|
||||
|
||||
// 登陆
|
||||
if (request->m_mph->mp_type() == mp::MP_REQUEST_LOGIN) {
|
||||
auto sri = service.login(request->m_body.subcommand(),
|
||||
|
||||
Reference in New Issue
Block a user