This commit is contained in:
wangyu- 2018-08-06 19:04:23 -05:00
parent 34d2ad19d2
commit 4b2865cf2e
2 changed files with 15 additions and 7 deletions

View File

@ -252,7 +252,7 @@ struct stat_t
}; };
struct conn_info_t //stores info for a raw connection.for client ,there is only one connection,for server there can be thousand of connection since server can struct conn_info_t:not_copy_able_t //stores info for a raw connection.for client ,there is only one connection,for server there can be thousand of connection since server can
//handle multiple clients //handle multiple clients
{ {
union tmp_union_t union tmp_union_t
@ -325,10 +325,11 @@ struct conn_info_t //stores info for a raw connection.for client ,there is o
{ {
last_active_time=get_current_time(); last_active_time=get_current_time();
} }
/*
conn_info_t(const conn_info_t &b) conn_info_t(const conn_info_t &b)
{ {
assert(0==1); assert(0==1);
} }*/
}; };
/* /*
struct conn_manager_t //manager for connections. for client,we dont need conn_manager since there is only one connection.for server we use one conn_manager for all connections struct conn_manager_t //manager for connections. for client,we dont need conn_manager since there is only one connection.for server we use one conn_manager for all connections

View File

@ -291,7 +291,7 @@ struct blob_decode_t
int output(int &n,char ** &output,int *&len_arr); int output(int &n,char ** &output,int *&len_arr);
}; };
class fec_encode_manager_t class fec_encode_manager_t:not_copy_able_t
{ {
private: private:
@ -422,10 +422,10 @@ struct fec_group_t
//int data_counter=0; //int data_counter=0;
map<int,int> group_mp; map<int,int> group_mp;
}; };
class fec_decode_manager_t class fec_decode_manager_t:not_copy_able_t
{ {
anti_replay_t anti_replay; anti_replay_t anti_replay;
fec_data_t *fec_data; fec_data_t *fec_data=0;
unordered_map<u32_t, fec_group_t> mp; unordered_map<u32_t, fec_group_t> mp;
blob_decode_t blob_decode; blob_decode_t blob_decode;
@ -443,15 +443,22 @@ public:
fec_decode_manager_t() fec_decode_manager_t()
{ {
fec_data=new fec_data_t[fec_buff_num+5]; fec_data=new fec_data_t[fec_buff_num+5];
assert(fec_data!=0);
clear(); clear();
} }
/*
fec_decode_manager_t(const fec_decode_manager_t &b) fec_decode_manager_t(const fec_decode_manager_t &b)
{ {
assert(0==1);//not allowed to copy assert(0==1);//not allowed to copy
} }*/
~fec_decode_manager_t() ~fec_decode_manager_t()
{ {
delete fec_data; mylog(log_debug,"fec_decode_manager destroyed\n");
if(fec_data!=0)
{
mylog(log_debug,"fec_data freed\n");
delete fec_data;
}
} }
int clear() int clear()
{ {