修复部分bug,添加内存池,为后续内存池化分配打基础
This commit is contained in:
17
c/network/protocal.h
Normal file
17
c/network/protocal.h
Normal file
@ -0,0 +1,17 @@
|
||||
#ifndef PROTOCAL
|
||||
#define PROTOCAL
|
||||
|
||||
typedef struct network_pakage
|
||||
{
|
||||
char *data;
|
||||
int buf_block;
|
||||
}network_package;
|
||||
|
||||
typedef struct net_protocal
|
||||
{
|
||||
void *protocal;
|
||||
int (*init)(void *self);
|
||||
int (*rev_message)(void *self,network_package *data);
|
||||
}net_protocal;
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user