mirror of
https://github.com/wangyu-/udp2raw.git
synced 2025-01-19 14:29:34 +08:00
refactor
This commit is contained in:
parent
8de2506eff
commit
f096a510b5
24
main.cpp
24
main.cpp
@ -8,27 +8,10 @@
|
|||||||
|
|
||||||
int mtu_warn=1375;//if a packet larger than mtu warn is receviced,there will be a warning
|
int mtu_warn=1375;//if a packet larger than mtu warn is receviced,there will be a warning
|
||||||
|
|
||||||
//uint64_t current_time_rough=0;
|
|
||||||
|
|
||||||
|
|
||||||
int VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV;
|
|
||||||
////////==============================variable divider=============================================================
|
|
||||||
|
|
||||||
|
|
||||||
int TTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTTT;
|
|
||||||
////////==========================type divider=======================================================
|
|
||||||
|
|
||||||
int server_on_raw_recv_pre_ready(conn_info_t &conn_info,char * ip_port,u32_t tmp_oppsite_const_id);
|
int server_on_raw_recv_pre_ready(conn_info_t &conn_info,char * ip_port,u32_t tmp_oppsite_const_id);
|
||||||
int server_on_raw_recv_ready(conn_info_t &conn_info,char * ip_port,char type,char *data,int data_len);
|
int server_on_raw_recv_ready(conn_info_t &conn_info,char * ip_port,char type,char *data,int data_len);
|
||||||
int server_on_raw_recv_handshake1(conn_info_t &conn_info,char * ip_port,char * data, int data_len);
|
int server_on_raw_recv_handshake1(conn_info_t &conn_info,char * ip_port,char * data, int data_len);
|
||||||
|
|
||||||
int DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD;
|
|
||||||
////////////////=======================declear divider=============================
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
int client_on_timer(conn_info_t &conn_info) //for client. called when a timer is ready in epoll
|
int client_on_timer(conn_info_t &conn_info) //for client. called when a timer is ready in epoll
|
||||||
{
|
{
|
||||||
//keep_iptables_rule();
|
//keep_iptables_rule();
|
||||||
@ -1005,8 +988,6 @@ int server_on_raw_recv_pre_ready(conn_info_t &conn_info,char * ip_port,u32_t tmp
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
int client_event_loop()
|
int client_event_loop()
|
||||||
{
|
{
|
||||||
|
|
||||||
@ -1533,11 +1514,6 @@ int server_event_loop()
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
int test()
|
int test()
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user