1
This commit is contained in:
parent
56640c5554
commit
7dbabffa09
@ -4,12 +4,18 @@
|
||||
|
||||
void MMCache::Init()
|
||||
{
|
||||
|
||||
socket_msg_buf_len_ = 1024 * 1024;
|
||||
udp_msg_buf_len_ = 1024 * 1024;
|
||||
socket_msg_buf_ = (char*)malloc(socket_msg_buf_len_);
|
||||
udp_msg_buf_ = (char*)malloc(udp_msg_buf_len_);
|
||||
}
|
||||
|
||||
void MMCache::UnInit()
|
||||
{
|
||||
|
||||
free(socket_msg_buf_);
|
||||
socket_msg_buf_ = nullptr;
|
||||
free(udp_msg_buf_);
|
||||
udp_msg_buf_ = nullptr;
|
||||
}
|
||||
|
||||
char* MMCache::AllocSocketMsg(int len)
|
||||
|
@ -22,6 +22,8 @@ public:
|
||||
private:
|
||||
|
||||
char* socket_msg_buf_ = nullptr;
|
||||
int socket_msg_buf_len_ = 1024;
|
||||
char* udp_msg_buf_ = nullptr;
|
||||
int udp_msg_buf_len_ = 1024;
|
||||
|
||||
};
|
||||
|
Loading…
x
Reference in New Issue
Block a user