wangyu 8 年 前
コミット
cea566f187
2 ファイル変更4 行追加2 行削除
  1. 1 1
      common.h
  2. 3 1
      main.cpp

+ 1 - 1
common.h

@@ -49,7 +49,7 @@
 #include<unordered_map>
 using  namespace std;
 
-const int max_data_len=800;
+const int max_data_len=1600;
 const int buf_len=max_data_len+200;
 const uint32_t max_handshake_conn_num=10000;
 const uint32_t max_ready_conn_num=1000;

+ 3 - 1
main.cpp

@@ -1462,7 +1462,9 @@ int server_on_raw_ready(conn_info_t &conn_info)
 		mylog(log_debug,"[%s][hb]received hb \n",ip_port);
 		conn_info.last_hb_recv_time = current_time_rough;
 		return 0;
-	} else if (data[0] == 'd' && data_len >=int( sizeof(uint32_t) + 1)) {
+	} else if (data[0] == 'd' && data_len >=int( sizeof(uint32_t) + 1))
+	{
+
 		uint32_t tmp_conv_id = ntohl(*((uint32_t *) &data[1]));
 
 		conn_info.last_hb_recv_time = current_time_rough;