优化network包长度字段自动计算

This commit is contained in:
duanhf2012
2023-03-20 15:20:04 +08:00
parent f3ff09b90f
commit 95b153f8cf
4 changed files with 13 additions and 32 deletions

View File

@@ -71,7 +71,6 @@ func (server *Server) Start(listenAddr string, maxRpcParamLen uint32) {
}
server.rpcServer.Addr = ":" + splitAddr[1]
server.rpcServer.LenMsgLen = 4 //uint16
server.rpcServer.MinMsgLen = 2
if maxRpcParamLen > 0 {
server.rpcServer.MaxMsgLen = maxRpcParamLen